title: Does Amazon S3 have a limit to MaxKeys when calling ListObjects?
body: <p>I always thought there was a 1,000 key limit when calling ListObjects in Amazon S3. However, I just made a call and it's pulling 1,080. But even their <a href="http://docs.aws.amazon.com/aws-sdk-php-2/latest/class-Aws.S3.S3Client.html#_listObjects" rel="noreferrer">docs</a> say there is a limit of 1,000.</p>
  
  <p>I tried setting the MaxKeys setting to 1,000 but it still pulls 1,080 results. My code:</p>
  
  <pre><code>$iterator = $s3-&gt;getIterator('ListObjects', array(
      'Bucket' =&gt; 'BUCKETNAME',
      'MaxKeys' =&gt; 1000
  ));
  </code></pre>
  
  <p>It is however pulling folders as keys. But I certainly don't have 80 of them.</p>
  
  <p>Two questions:</p>
  
  <ol>
  <li>Is my code wrong?</li>
  <li>Has Amazon lifted the 1000 key restriction? Is there a new limit?</li>
  </ol>
  
  <p>Thanks in advance!</p>