Adding HTML Code in Text area

How can I add a text field in which I can paste HTML code, which is then displayed on the website untouched?

Currently, when I do it the HTML tags still show. I literally don’t want the formatting of the code I paste in to be changed at all.

This will be for custom head scripts, user-generated cookie policies etc.

Can you please post an example of what you put into your textarea field and how you output the field in your template? Adding HTML shouldn’t be a problem.