js copy node and append to parent code example Example: appendchild on specific position parentElement.insertBefore(newElement, parentElement.children[2]);