# Forum Code Formatting

**URL:** <https://forum.freecodecamp.org/t/forum-code-formatting/25574>\
**Category:** freeCodeCamp Contributors\
**Tags:** guide\
**Created:** [August 5, 2016, 5:53am UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574 "2016-08-05T05:53:31Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![JacksonBates](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/jacksonbates/32/123402_2.png) [@JacksonBates](https://forum.freecodecamp.org/u/JacksonBates)\
**Post date:** [August 5, 2016, 5:53am UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/1 "2016-08-05T05:53:31Z")

</div>

_This post is modeled on [Markdown Code Formatting - freeCodeCamp Community - The freeCodeCamp Forum](http://forum.freecodecamp.com/t/markdown-code-formatting/18391), but modified for the slight differences between the Forum and Gitter. If you are interested in using Spoiler blocks, check this post: [Spoilers](http://forum.freecodecamp.com/t/forum-tip-add-spoilers-when-showing-code-samples/21253?u=jacksonbates)._

You can post code in two ways. Single word/line snippets can be handled inline. Multiple lines should be handled in code blocks:

## Inline

Wrap your code in a single back ticks:

Example:

 ![](https://global.discourse-cdn.com/freecodecamp/original/2X/b/b3b69e0644a782988fcc3fbc07f89007451f6857.gif)

## Code Blocks

Wrap your code in triple back ticks, with **new lines** between the back ticks and code:

Example:

 ![](https://global.discourse-cdn.com/freecodecamp/original/2X/4/470db50cc014204906db4a54e53a7442df544643.gif)

## Typing Backticks[⤴](http://superuser.com/a/254077/122424)

### QWERTY and QWERTZ (Key that’s been marked with red border)

### AZERTY France (Alt Gr + Key that’s been marked with red border)

### AZERTY Belgium (Alt Gr + Key that’s been marked with red border)

### QWERTY Estonian (Key’s that have been marked with red border)

 ![Estonian Keyboard layout](https://sea3.discourse-cdn.com/freecodecamp/uploads/default/original/2X/0/089b26510b1dcc7553625ba162582cf55837b6cd.png)

### QWERTZ ( **SHIFT+double press** the key that’s been marked with red border)

 ![QWERTZ](https://global.discourse-cdn.com/freecodecamp/original/3X/0/9/09e513f32ed08ffb30a0a997aa5a2d42760068ba.png)

### If it’s not there…

You can use the code `Alt+0096` to get a backtick on any keyboard with a numeric pad

---

<div class="post-metadata">

**Author:** ![theshocktart](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/theshocktart/32/75639_2.png) [@theshocktart](https://forum.freecodecamp.org/u/theshocktart)\
**Post date:** [April 5, 2017, 2:23am UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/2 "2017-04-05T02:23:49Z")

</div>

Thanks!!  
I had so much trouble with that

---

<div class="post-metadata">

**Author:** ![auctionchick](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/auctionchick/32/162578_2.png) [@auctionchick](https://forum.freecodecamp.org/u/auctionchick)\
**Post date:** [May 12, 2017, 3:25pm UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/3 "2017-05-12T15:25:48Z")

</div>

Thanks for being so kind to teach me this trick.  
When you’re knew, the simplest thing can derail you. I was thinking “I clearly should not be a programmer if I can’t even figure out how to post to the forum properly.”

---

<div class="post-metadata">

**Author:** ![mcne65](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/mcne65/32/61920_2.png) [@mcne65](https://forum.freecodecamp.org/u/mcne65)\
**Post date:** [June 12, 2018, 11:25am UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/4 "2018-06-12T11:25:03Z")

</div>

I am having problems with my Windows laptop to make this work. Do you know how to resolve this issue?

---

<div class="post-metadata">

**Author:** ![tough](https://avatars.discourse-cdn.com/v4/letter/t/e274bd/32.png) [@tough](https://forum.freecodecamp.org/u/tough)\
**Post date:** [August 7, 2018, 5:08am UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/5 "2018-08-07T05:08:19Z")

</div>

Thanks alot sir for teaching me this…its really good

---

<div class="post-metadata">

**Author:** ![ILM](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/ilm/32/363239_2.png) [@ILM](https://forum.freecodecamp.org/u/ILM)\
**Post date:** [February 8, 2019, 8:50am UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/6 "2019-02-08T08:50:31Z")

</div>

Or for everyone that doesn’t have the backtick in the keyboard (looking at you Italian QWERTY…): `ALT + 0096` (Windows)

---

<div class="post-metadata">

**Author:** ![MatteoCarotta](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/matteocarotta/32/121142_2.png) [@MatteoCarotta](https://forum.freecodecamp.org/u/MatteoCarotta)\
**Post date:** [August 9, 2019, 6:58pm UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/8 "2019-08-09T18:58:31Z")

</div>

### QWERTZ ( **SHIFT+double press** the key that’s been marked with red border)

 ![QWERTZ](https://global.discourse-cdn.com/freecodecamp/original/3X/0/9/09e513f32ed08ffb30a0a997aa5a2d42760068ba.png)

---

<div class="post-metadata">

**Author:** ![ILM](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/ilm/32/363239_2.png) [@ILM](https://forum.freecodecamp.org/u/ILM)\
**Post date:** [August 10, 2019, 8:08am UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/9 "2019-08-10T08:08:09Z")

</div>

thank you - I am adding this to the top post if you don’t mind

---

<div class="post-metadata">

**Author:** ![MatteoCarotta](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/matteocarotta/32/121142_2.png) [@MatteoCarotta](https://forum.freecodecamp.org/u/MatteoCarotta)\
**Post date:** [August 10, 2019, 9:59am UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/10 "2019-08-10T09:59:33Z")

</div>

Go ahead, I’m just glad it can be useful.

---

<div class="post-metadata">

**Author:** ![ClaraSais](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/clarasais/32/261518_2.png) [@ClaraSais](https://forum.freecodecamp.org/u/ClaraSais)\
**Post date:** [January 17, 2020, 8:37pm UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/11 "2020-01-17T20:37:30Z")

</div>

I’ve never heard of back ticks before and still slightly unclear about what they are. As a newbie I’m stuck on some code and posted it without these and obviously advised to put them in. I’m working in the UK on a MacBook keyboard, any ideas please where I would find them? TIA

---

<div class="post-metadata">

**Author:** ![ClaraSais](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/clarasais/32/261518_2.png) [@ClaraSais](https://forum.freecodecamp.org/u/ClaraSais)\
**Post date:** [February 7, 2020, 8:42pm UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/13 "2020-02-07T20:42:33Z")

</div>

Thank you I will shortly

---

<div class="post-metadata">

**Author:** ![Greatone](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/greatone/32/136132_2.png) [@Greatone](https://forum.freecodecamp.org/u/Greatone)\
**Post date:** [March 31, 2020, 8:59pm UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/14 "2020-03-31T20:59:30Z")

</div>

Thank you for the backtick (ALT+0096) now I can move forward with confidence you are a GREAT HELP!!

---

<div class="post-metadata">

**Author:** ![chuckadams](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/chuckadams/32/109651_2.png) [@chuckadams](https://forum.freecodecamp.org/u/chuckadams)\
**Post date:** [March 31, 2020, 9:07pm UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/15 "2020-03-31T21:07:06Z")

</div>

You don’t need the backtick key, just hilight the text and press the `</>` button in the editor. This one:

 ![image](https://global.discourse-cdn.com/freecodecamp/original/3X/8/3/8338d3650504278680d68f50f9d86b96fea2a77b.png)

The standard response really should be changed to that.

---

<div class="post-metadata">

**Author:** ![Greatone](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/greatone/32/136132_2.png) [@Greatone](https://forum.freecodecamp.org/u/Greatone)\
**Post date:** [April 2, 2020, 9:19pm UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/18 "2020-04-02T21:19:31Z")

</div>

Thank you I found the backtick on the internet thank you for your reply.

---

<div class="post-metadata">

**Author:** ![racheltodd50](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/racheltodd50/32/142026_2.png) [@racheltodd50](https://forum.freecodecamp.org/u/racheltodd50)\
**Post date:** [April 12, 2020, 3:49am UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/19 "2020-04-12T03:49:37Z")

</div>

Hi, what html editor do you use for this example?

---

<div class="post-metadata">

**Author:** ![ILM](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/ilm/32/363239_2.png) [@ILM](https://forum.freecodecamp.org/u/ILM)\
**Post date:** [April 12, 2020, 6:38am UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/20 "2020-04-12T06:38:37Z")

</div>

do you mean this?

> [@JacksonBates](#):
>
> Example:
> 
> ![block code.gif](https://sea3.discourse-cdn.com/freecodecamp/uploads/default/original/2X/4/470db50cc014204906db4a54e53a7442df544643.gif)

that’s not an html editor, it’s the forum editor and preview, maybe the old version for the colors, but it works the same

---

<div class="post-metadata">

**Author:** ![Anita-joseph](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/anita-joseph/32/141393_2.png) [@Anita-joseph](https://forum.freecodecamp.org/u/Anita-joseph)\
**Post date:** [May 12, 2020, 10:10pm UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/21 "2020-05-12T22:10:19Z")

</div>

Thanks for this post. It s very useful one 🙂  
it s very well explained 🙂  
👍🏼

---

<div class="post-metadata">

**Author:** ![kamalhere](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/kamalhere/32/176878_2.png) [@kamalhere](https://forum.freecodecamp.org/u/kamalhere)\
**Post date:** [September 2, 2020, 5:44pm UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/22 "2020-09-02T17:44:13Z")

</div>

Thanks for the trick, bro 😃 😃

---

<div class="post-metadata">

**Author:** ![tesnim](https://avatars.discourse-cdn.com/v4/letter/t/4da419/32.png) [@tesnim](https://forum.freecodecamp.org/u/tesnim)\
**Post date:** [September 7, 2020, 4:54pm UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/23 "2020-09-07T16:54:01Z")

</div>

i still think though 🤔 am having trouble with the backticks

---

<div class="post-metadata">

**Author:** ![ILM](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/ilm/32/363239_2.png) [@ILM](https://forum.freecodecamp.org/u/ILM)\
**Post date:** [January 16, 2021, 11:26am UTC](https://forum.freecodecamp.org/t/forum-code-formatting/25574/24 "2021-01-16T11:26:46Z")

</div>

Closed on January 16, 2021, 11:26am UTC


