Home / Javascript Tips Generated By ChatGPT / Creating Deep Copies of Objects in Javascript Use JSON.parse and JSON.stringify to create a deep copy of an object. Source Code let original = { name: 'John', address: { city: 'New York' } }; let copy = JSON.parse(JSON.stringify(original));