# All code deleted after pasting HTML into Code Mode

**URL:** <https://forum.mautic.org/t/all-code-deleted-after-pasting-html-into-code-mode/17426>\
**Category:** Product Support\
**Created:** [December 16, 2020, 2:09am UTC](https://forum.mautic.org/t/all-code-deleted-after-pasting-html-into-code-mode/17426 "2020-12-16T02:09:58Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![gvfreeman](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/gvfreeman/32/1090_2.png) [@gvfreeman](https://forum.mautic.org/u/gvfreeman)\
**Post date:** [December 16, 2020, 2:09am UTC](https://forum.mautic.org/t/all-code-deleted-after-pasting-html-into-code-mode/17426/1 "2020-12-16T02:09:58Z")

</div>

**Your software**  
My Mautic version is: 2.16.2  
My PHP version is: 7.3.23

**Your problem**  
When I copy the HTML code from Mailchimp from this email ([https://us7.campaign-archive.com/?u=7c28c61e5a8c91586da3e166a&id=17b64b62db](https://us7.campaign-archive.com/?u=7c28c61e5a8c91586da3e166a&id=17b64b62db)) and paste it into Code Mode inside of a new Mautic email is looks perfectly fine. Then I click Apply and try and preview the email and all the code except the snippet below has been deleted. I’ve also tried clicking “Format Code” before Applying that it does the same thing. Does anyone know why this is happening or how I can fix it?

### 
 \<meta property="og:title" content="🚀 Shift into a 2021 state of mind ###

---

<div class="post-metadata">

**Author:** ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)\
**Post date:** [December 16, 2020, 2:50pm UTC](https://forum.mautic.org/t/all-code-deleted-after-pasting-html-into-code-mode/17426/2 "2020-12-16T14:50:03Z")

</div>

Hi,  
First copy the content into Mautic’s code box. Then a little trick: try to click once outside of the editing area in Mautic before you save.

Don’t forget to change webview\_url, unsubscribe\_url!

Good luck.  
Joey
