Pen Settings



CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource


Babel is required to process package imports. If you need a different preprocessor remove all packages first.

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


Save Automatically?

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.


                <div class="container">
  <h1>The following content uses block and inline layout</h1>
  <p>Block elements extend to fill the container in the inline direction. They break onto a new line. Any inline elements such as a <span>span</span> do not break onto a new line.</p>
  <div class="media">
    <div class="img"><img src="" alt="balloons"></div>
    <div class="content">
      <h2>Media Object</h2>
      <p>Content inside the flex item returns to normal flow layout.</p>
  <p>Unless you change the value of display, elements continue to display using these block and inline rules.</p>


                body {
  padding: 20px;
  font: 1em Helvetica Neue, Helvetica, Arial, sans-serif;
  background-color: rgb(192,181,129);

.media {
  display: flex;
  border: 5px solid rgb(209,54,114);
  padding: 1em;

.media .img {
  width: 100px;
  margin: 0 1em 0 0;

span {
  color: rgb(209,54,114);
  font-weight: bold;

.container {
  margin: 0 auto;
  padding: 20px;
  max-width: 700px;
  background-color: rgba(255,255,255,.6);

img {
  max-width: 100%;