Like _.zipObject, but each prop is a property path (dots and brackets). Lodash builds nested objects/arrays — same path rules as _.set. Part of Lodash 4.x Array.
Pass the required arguments shown below. Lodash Array helpers usually return a new value — check whether the source array is mutated.
Syntax
Call _.zipObjectDeep on an array. Start with this line.
Lodash
_.zipObjectDeep([props=[]], [values=[]])
Call
What it does
_.zipObjectDeep([props=[]], [values=[]])
Primary signature.
_.zipObjectDeep(array)
Call with an array argument.
Prefer import zipObjectDeep from "lodash/zipObjectDeep" when you want a smaller bundle.
_.zipObjectDeep is a Lodash 4.x Array helper. It runs anywhere Lodash runs — modern browsers (via CDN or bundle) and Node.js / Bun / Deno with npm install lodash.
✓ Stable · Lodash 4.x
_.zipObjectDeep()
Available in [email protected] full builds and the lodash/zipObjectDeep modular import. Works in evergreen browsers and current Node LTS when Lodash is installed.
100%With Lodash 4.x
Google ChromeSupported · Desktop & Mobile
Full support
Mozilla FirefoxSupported · Desktop & Mobile
Full support
Apple SafariSupported · macOS & iOS
Full support
Microsoft EdgeSupported · Chromium
Full support
Internet ExplorerNo native support · Use a polyfill
Polyfill
OperaSupported · Modern versions
Full support
Samsung InternetSupported · Android
Full support
BunSupported · JavaScript runtime
Supported
DenoSupported · JavaScript runtime
Supported
Node.jsSupported · Server runtime
Supported
Android WebViewSupported · Modern WebView
Full support
_.zipObjectDeepLodash 4.x+
Bottom line: Safe for production once Lodash is on the page or in your bundle. Prefer import zipObjectDeep from "lodash/zipObjectDeep" for smaller builds. Not a native browser API — load Lodash first.
Frequently Asked Questions
_.zipObjectDeep(props, values) builds a nested object by pairing each property path in props with the value at the same index. Paths use dots and brackets, like _.set.
No. It returns a new nested object. The props and values arrays stay unchanged.
zipObject treats each prop as one literal key (so "a.b" stays flat). zipObjectDeep parses paths and creates nested objects or arrays.
Use brackets such as items[0].sku. Lodash allocates arrays at numeric segments.
Later assignments win. Shared prefixes merge into the same parent until a later value replaces an intermediate node.
Use import zipObjectDeep from "lodash/zipObjectDeep" or require("lodash/zipObjectDeep") for tree-shaking. Full build: import _ from "lodash" then _.zipObjectDeep.