There may be times when you want to use HTML in your WordPress website. For example you may prefer to code a hyperlink by hand, or adjust the header sizes. In this tutorial we will show you how to view/add HTML code to a Page or Post in WordPress.

As per WordPress' official Code support page, Javascript, and other embeds such as Flash are not allowed to be added to a Page or Post in WordPress.

Here is a list of the specific HTML tags that WordPress allows: address, a, abbr, acronym, area, article, aside, b, big, blockquote, br, caption, cite, class, code, col, del, details, dd, div, dl, dt, em, figure, figcaption, footer, font, h1, h2, h3, h4, h5, h6, header, hgroup, hr, i, img, ins, kbd, li, map, ol, p, pre, q, s, section, small, span, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, var

How to Add HTML to a Page/Post:

  1. Login to the Dashboard for WordPress.
  2. In the navigation menu click the Pages or Posts link, depending which one you want to add HTML to. In my tests I clicked Posts.
  3. Now, click the page or post that you want to edit.

  4. Click the Text tab.

    You will then see the text of the page or post and you can enter the HTML. In my Tests I am adding a Link to an email address:

  5. Click the Update button to save your changes.
    Here is view of the HTML link I added to a Post:


Congratulations, now you know how to add HTML to a WordPress Page or Post!

Continued Education in Course 101: An introduction to WordPress
You are viewing Section 15: Adding HTML to a Wordpress Page/Post
Section 14: Creating a WordPress Page
Did you find this article helpful?

We value your feedback!

Why was this article not helpful? (Check all that apply)
The article is too difficult or too technical to follow.
There is a step or detail missing from the instructions.
The information is incorrect or out-of-date.
It does not resolve the question/problem I have.
How did you find this article?
Please tell us how we can improve this article:
Email Address
Name

new! - Enter your name and email address above and we will post your feedback in the comments on this page!

n/a Points
2014-07-16 6:35 pm
when I added the html code, the html code showed up not the link.
Staff
9,576 Points
2014-07-17 2:05 pm
This can happen if you are in the visual mode instead of the text mode. Be sure to click on the Text tab before inputting your code.
n/a Points
2014-07-19 7:25 am
It is so easy i want advance
Staff
20,340 Points
2014-07-21 1:20 pm
Hello abc,

We would be happy to create more articles for in-demand topics. Please let us know if you have any particular thing you need to see.

Kindest Regards,
Scott M
n/a Points
2014-09-05 3:38 am

how can integrete html page into wordpress.

write step by step.

Staff
20,340 Points
2014-09-05 8:47 am
Hello Umang,

This article is entirely about just that. Just follow the instructions above and you should be fine. You are welcome to ask any specific questions here in the comments.

Kindest Regards,
Scott M
n/a Points
2014-10-09 2:54 am

I want to add html code inside the blog, like if i do <html>...</html>, this <html>...</html> should be printed as it is on the blog.  how do i do that?

Staff
20,340 Points
2014-10-09 8:23 am
Hello Tehreem,

If you wish for the tags to be visible, they will display as you type them if you are using the 'Visual' mode when creating a post or page. If you are in the 'Text' mode, then it assumes you want to use the code in your post and it will not display but be used for formatting. You can switch back and forth as needed while creating your pages or posts in WordPress.

Kindest Regards,
Scott M
n/a Points
2014-11-15 10:49 am

Hi Scott,

That is useful and confirms what I had suspected BUT to add Google Analytics/Webmaster tools you need to get into the 'head', not the body, from what I see only the 'body' is exposed in the text viewer...or am I missing something?

Regards

Brian

Staff
10,371 Points
2014-11-17 9:34 am
Hello Brian,

Thank you for your WordPress question. I found many posts in the WordPress forum, where they suggest using a plugin such as Google Analytics by Yoast.

Alternately, you can edit the code for your theme, and add the the Google code to the header.php. This file location may differ based on your specific theme.

Thank you,
John-Paul
n/a Points
2014-11-19 6:56 am

Hi JP,

Thanks for such a quick response. If it is not too early have a great Christmas.

 

Regards

Brian

n/a Points
2014-11-18 4:45 pm

I followed your steps and yes it should work.  It does paste in text, when I go to visual I see the blank box for my embed, then when I reload my site to view, nothing shows up.  I am pasting in text only not in visual.  I'm trying to embed a book I am recommending from Amazon. 

Staff
9,576 Points
2014-11-18 6:02 pm
To narrow down the issue, when pasting in the text view, and saving your changes without switching back to the visual editor, are your changes in place?

Post a Comment

Name:
Email Address:
Phone Number:
Comment:
Submit

Please note: Your name and comment will be displayed, but we will not show your email address.

13 Questions & Comments

Post a comment

Back to first comment | top

Need more Help?

Search

Ask the Community!

Get help with your questions from our community of like-minded hosting users and InMotion Hosting Staff.

Current Customers

Chat: Click to Chat Now E-mail: support@InMotionHosting.com
Call: 888-321-HOST (4678) Ticket: Submit a Support Ticket

Not a Customer?

Get web hosting from a company that is here to help. Sign up today!