title: The remote server returned an error: (413) Request Entity Too Large. Elasticsearch and JSON
body: <p>I am trying to add a JSON file (263 MB) into elasticsearch. I already created a mapping for this file using Kibana, now I am trying to add it into elastic search. I am running this command in PowerShell.</p>
  
  <p><code>C:\Users\Khan&gt; Invoke-RestMethod "http://localhost:9200/mysofindex/_bulk?pretty" -Method Post -ContentType 'application/x-ndjson' -InFile "output.json"</code></p>
  
  <p>but this gives me an error. something like this:</p>
  
  <pre><code>Invoke-RestMethod : The remote server returned an error: (413) Request Entity Too Large.
  At line:1 char:1
  + Invoke-RestMethod "http://localhost:9200/mysofindex/_bulk?pretty" -Me ...
  + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      + CategoryInfo          : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-RestMethod], WebE 
     xception
      + FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeRestMethodCommand
  </code></pre>
  
  <p>Please tell me how can i solve this problem?</p>