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. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ 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.


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.


                <h1>Flat UI - Custom Input:file</h1>
<h2>With only CSS</h2>

<form action="#">
  <p class="file">
    <input type="file" name="file" id="file" />
    <label for="file">Upload your image</label>

<p class="txtcenter">It's just a test, not really usable.<br />Works on IE &gt; 8 and modern browsers</p>
<p class="txtcenter copy">by <a href="">@geoffreycrofte</a><br />see also <a href="">CSS custom Checkboxes</a></p>


.file {
  position: relative;
.file label {
  background: #39D2B4;
  padding: 5px 20px;
  color: #fff;
  font-weight: bold;
  font-size: .9em;
  transition: all .4s;
.file input {
  position: absolute;
  display: inline-block;
  left: 0;
  top: 0;
  opacity: 0.01;
  cursor: pointer;
.file input:hover + label,
.file input:focus + label {
  background: #34495E;
  color: #39D2B4;

/* Useless styles, just for demo styles */

body {
  font-family: "Open sans", "Segoe UI", "Segoe WP", Helvetica, Arial, sans-serif;
  color: #7F8C9A;
  background: #FCFDFD;
h1, h2 {
  margin-bottom: 5px;
  font-weight: normal;
  text-align: center;
h2 {
  margin: 5px 0 2em;
  color: #1ABC9C;
form {
  width: 225px;
  margin: 0 auto;
h2 + P {
  text-align: center;
.txtcenter {
  margin-top: 4em;
  font-size: .9em;
  text-align: center;
  color: #aaa;
.copy {
 margin-top: 2em; 
.copy a {
 text-decoration: none;
 color: #1ABC9C;


                // no js