title: What is the difference between the 'COPY' and 'ADD' commands in a Dockerfile?
body: <p>What is the difference between the <code>COPY</code> and <code>ADD</code> commands in a Dockerfile, and when would I use one over the other?</p>
  
  <pre><code>COPY &lt;src&gt; &lt;dest&gt;
  </code></pre>
  
  <blockquote>
    <p>The COPY instruction will copy new files from <code>&lt;src&gt;</code> and add them to the container's filesystem at path <code>&lt;dest&gt;</code></p>
  </blockquote>
  
  <pre><code>ADD &lt;src&gt; &lt;dest&gt;
  </code></pre>
  
  <blockquote>
    <p>The ADD instruction will copy new files from <code>&lt;src&gt;</code> and add them to the container's filesystem at path <code>&lt;dest&gt;</code>.</p>
  </blockquote>