Pen Settings



CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource


Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource


Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.


Auto Save

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.


   <h1>Heading 1</h1>
   <h2>Heading 2</h2>
   <h3>Heading 3</h3>
   <h4>Heading 4</h4>
   <h5>Heading 5</h5>
   <h6>Heading 6</h6>
   <p>Lorem ipsum, dolor sit amet consectetur adipisicing elit. Quos natus alias sequi fugit. Reprehenderit facere eaque est ducimus consequatur possimus? Autem laborum magnam harum tempore tempora corporis nam similique iusto!</p>
   <p><em>(Change the size of the browser window between mobile and desktop resolution to see the scaling effect.)</em></p>


                :root {
   --font-size--0: clamp(1rem, calc(0.89rem + 0.54vw), 1.38rem);
   --font-size--1: clamp(1.2rem, calc(1.07rem + 0.64vw), 1.65rem);
   --font-size--2: clamp(1.44rem, calc(1.29rem + 0.77vw), 1.98rem);
   --font-size--3: clamp(1.73rem, calc(1.54rem + 0.93vw), 2.38rem);
   --font-size--4: clamp(2.07rem, calc(1.85rem + 1.11vw), 2.85rem);
   --font-size--5: clamp(2.49rem, calc(2.22rem + 1.33vw), 3.42rem);
   --font-size--6: clamp(2.99rem, calc(2.67rem + 1.6vw), 4.11rem);

   --spacer: clamp(1rem, calc(0.89rem + 0.54vw), 1.38rem);

   --article--side-padding: calc(var(--spacer) / 2);
   --article--max-width: 45rem;

body {
   font-family: sans-serif;
   font-size: var(--font-size--0);

em {
   font-style: normal;
   font-size: 0.65em;
   color: red;

article {
   padding-left: var(--article--side-padding);
   padding-right: var(--article--side-padding);
   max-width: var(--article--max-width);
   margin-left: auto;
   margin-right: auto;

article > * {
   margin-top: 0;
   margin-bottom: 0;

article > * + * {
   margin-top: var(--spacer);

h6 {
   font-size: var(--font-size--1);

h5 {
   font-size: var(--font-size--2);

h4 {
   font-size: var(--font-size--3);

h3 {
   font-size: var(--font-size--4);

h2 {
   font-size: var(--font-size--5);

h1 {
   font-size: var(--font-size--6);