header-logo
Learn how to use Wix to build your site and business.
Design and manage your site using intuitive Wix features.
Manage subscriptions, plans and invoices.
Run your business and connect with members.
Learn to purchase, connect or transfer a domain to your site.
Get tools to grow your business and web presence.
Boost your visibility with SEO and marketing tools.
Get advanced features to help you work more efficiently.
Find solutions, learn about known issues or contact us.
placeholder-preview-image
Improve your skills with our courses and tutorials.
Get tips for web design, marketing and more.
Learn to increase organic site traffic from search engines.
Build a custom site using our full-stack platform.
Get matched with a specialist to help you reach your goals.
placeholder-preview-image

Wix Blog: Adding a Code Snippet to a Blog Post

1 min
With the Code Snippet feature in your post toolbar, you can showcase a piece of formatted code within your blog post. This can be especially useful for bloggers who write about programming, web development, and similar topics.

To add a code snippet to a blog post:

  1. Go to the Blog tab in your site's dashboard. 
  2. Click Create New Post or click Edit on an existing post.
  3. Add a post title.
  4. Add the post content, including the code.
  5. Highlight the code. 
  6. Click the Code Snippet iconto format the code.
  7. When you're ready, click Publish
A screenshot showing a piece of code being added to a blog post.
A screenshot showing a piece of code being added to a blog post.