The website lets you download search results by clicking on the Download Results link from the search results page:
Choose the number of results to download:
The number of results you can download is based on the number of query credits your account has available. And the Shodan API has a hard limit of 1 million results per query. For example, if the search query has 30 million results then you would at maximum be able to download 1 million of those results. To download the full search results you would need to break the query into smaller queries where each of them fits within the 1 million limit.
After submitting the request you will be redirected to the Downloads section of the website with a progress bar to let you know when the data is available:
Downloads are retained for 30 days after which they expire from the website. Please ensure you download the data before it expires!