Quick answer: To embed a tweet (now called an X post), open the post on x.com, click the menu icon, choose Embed post, customize it on publish.x.com and click Copy Code. Paste the code into an HTML or code block on your website. In WordPress, you can also paste the post’s URL into the editor or an Embed block and WordPress turns it into an embed.

How to embed a tweet or X post on a website

Embedding a post keeps its formatting, media, links and author details, and it lets readers like or reply on X. This guide covers single posts, WordPress, timelines and the most common errors.

How do you embed a tweet on a website?

Steps to embed an X post with publish.x.com

X’s help article on how to embed a post describes the process:

  1. Open the post on x.com in a desktop browser.
  2. Click the menu icon on the post and select Embed post.
  3. On publish.x.com, click set customization options to choose a light or dark theme, or Hide Conversation to hide the post it replies to.
  4. Click Copy Code.
  5. Paste the code into your page’s HTML, an HTML block or a code block.

X notes that embedding posts is only available via x.com, so use the website rather than the mobile app.

How do you embed a tweet in WordPress?

  • Paste the link: copy the post URL and paste it on its own line in the block editor. WordPress converts X links into embeds automatically.
  • Embed block: add the X (Twitter) embed block and paste the URL.
  • Custom HTML: paste the code from publish.x.com into a Custom HTML block for full control over options.
  • Classic editor: use the Text tab when pasting embed code.

How do you embed an X timeline or feed?

publish.x.com can also generate embedded timelines for a profile. For a fully designed feed with moderation, multiple accounts or hashtags, use a feed widget. We compare the options in our guide to the best Twitter feed widget tools.

OptionShowsDesign controlBest for
————
Embedded postOne postTheme and conversation optionsQuoting a post in an article
Embedded timelineRecent posts from a profileLimitedA simple profile feed
Feed widgetPosts from accounts or hashtagsHighBranded feeds and social walls

How do you embed X posts for developers?

X’s embedded posts documentation explains how to convert a post URL into embed markup with the oEmbed API, or render posts with X’s widgets JavaScript, which turns blockquote elements into fully rendered posts.

Why is my embedded tweet showing as plain text?

  • The script did not load. The embed code includes a script that turns the blockquote into a post. If your editor strips scripts, use an HTML or code block.
  • The account is protected. Posts from protected accounts cannot be embedded.
  • The post was deleted. A deleted post can no longer render.
  • Privacy tools block X. Ad blockers and cookie consent tools may block the script until visitors give consent.

Should you embed tweets or take screenshots?

Embedding is usually better. Embedded posts stay accurate, keep links clickable, credit the author and let readers interact. Screenshots can be edited, go stale and are harder for screen readers. Use screenshots only when you need a permanent record of a post that may be deleted, and add alt text.

If you also want to show other social content, see our guides to the TikTok feed widget tools and the social media wall for events.

Frequently asked questions

Can I still embed tweets after Twitter became X?

Yes. The Embed post option and publish.x.com still generate embed code.

Can I embed a tweet with a video?

Yes. Embedded posts show photos and videos uploaded to X.

How do I embed a tweet without the reply it responds to?

On publish.x.com, open the customization options and check Hide Conversation.

Can I embed tweets from a protected account?

No. Embed code is not available for posts from protected accounts.

Do embedded tweets slow down a page?

Each embed loads X’s script. Limit the number of embeds per page, or use a lightweight feed widget for many posts.

Leave a Reply

How to embed a tweet or X post on a website

We are Widgets Code

widgets

From social media feed widgets and review widgets to social walls and embeddable website experiences, Widgets Code helps marketers and businesses find, compare, and implement the right widgets for their websites.

Recent posts

website widgets
widgets code blog

Contact us

Want a customized widget code for your website? Contact us trough the form below and get it done for you!

← Back

Thank you for your response. ✨

Create your own website, free on WordPress.com.Create your own website.
Start free