How to Save Google Sheets as CSV (4 Easy Ways)

Table of Contents

Table of Contents

We can easily manage and analyse data using Google Sheets. Sometimes, we need to save our Google Sheets data in CSV (Comma-Separated Values) format. CSV format is widely used because itโ€™s lightweight, supported by almost every application, and easy to share. In this article, weโ€™ll explore all the methods for saving Google Sheets as CSV.

Key Takeaways

To save Google Sheets as CSV format, you need to follow these steps:

โžค Open your Google Sheet.
โžค From the top menu, click File > Download.
โžค Select Comma Separated Values (.csv). The current sheet will be downloaded in .csv format.

overview image

In this article, we will learn how to save Google Sheets as CSV using various methods. Download as CSV, Publish to the Web as CSV, Export Using Google Apps Script, Copy and Paste into a Text Editor are the ways to save Google Sheets as CSV.


1

Download as CSV from Google Sheets

Letโ€™s consider the dataset below, where we have order ID, Customer Name, Product, Quantity and Price Columns.

Download as CSV from Google Sheets

Steps:

โžค Go to the top menu and click File > Download.
โžค Select Comma Separated Values (.csv). The Current Sheet will be saved as a .csv format on your computer.
โžค To save multiple sheets, you need to repeat these steps for each sheet and save them with a different name. All the sheets will be saved in a .csv format.

Download as CSV from Google Sheets


2

Publish to the Web as CSV

By publishing Google Sheets to the web in CSV format, you can save Google Sheets.  After publishing the sheet on the web, you can obtain a link to access the file at any time.

Steps:

โžค Go to File > Share > Publish to web.

Publish to the Web as CSV

โžค Choose โ€œEntire Documentโ€ or the sheet you want to publish and click the Publish button

Publish to the Web as CSV

โžค Now, a pop-up will come to confirm your publishing. Click OK.

Publish to the Web as CSV

โžค Copy the generated link.

Publish to the Web as CSV

โžค Now, anyone with the link can download the sheet as a CSV file.


3

Export as CSV Using Google Apps Script

Google Apps Script is the advanced option to save Google Sheets as CSV. The Sheet will be saved in the Google Drive in CSV format.

Steps:

โžค Go to Extensions > Apps Script.

Export as CSV Using Google Apps Script

โžค Paste this code and click Run.

function saveAsCSV() {
var sheet = SpreadsheetApp.getActiveSpreadsheet().getActiveSheet();
var data = sheet.getDataRange().getValues();
var csv = "";
data.forEach(function(row) {
csv += row.join(",") + "\n";
});
var file = DriveApp.createFile(sheet.getName() + ".csv", csv);
Logger.log("File saved as: " + file.getUrl());
}

Export as CSV Using Google Apps Script

โžค A pop-up window will appear to review permission. Click on the โ€œReview Permissionsโ€ Button.

Export as CSV Using Google Apps Script

โžค After giving permission, code execution will begin, and the file will be saved in CSV format on Google Drive.

Export as CSV Using Google Apps Script


4

Copy and Paste into a Text Editor

Copying and pasting into a text editor is the quickest and manual way to save Google Sheets in CSV format. In the text editor file, you can save the data with a .csv extension.

Steps:

โžค Select the entire dataset and press  Ctrl  +  C  (for windows) /  Cmd  +  C  (for MAC) to copy the dataset.

Copy and Paste into a Text Editor

โžค Paste the data into Notepad (Windows) or TextEdit (Mac) and click File> Save Asโ€ฆ

Copy and Paste into a Text Editor

โžค Write the file name with the .csv extension and click Save.

Copy and Paste into a Text Editor


Practice Resources

Get our practice workbook or necessary files that we have worked with to prepare this article.

Save as CSV in Google Sheets [Make a Copy]


Frequently Asked Questions (FAQs)

Will the formulas, bold text, and color formatting remain the same in CSV files?

No. The only data is stored in the CSV file. Formulas and formatting (borders, colors, and fonts) will be lost in the CSV file. Only the calculated values will be the same.

Is it possible to save only selected rows or columns as CSV?

By default, Google Sheets saves the entire sheet. But it is possible to save only the selected rows or columns as CSV. To save only the selected rows or columns, copy them into a new sheet and then download that sheet as a CSV file.

Can I save Google Sheets as a CSV file directly on my mobile device?

Yes, you can save Google Sheets as CSV directly on mobile devices using the Google Sheets mobile app. At first, you need to open the sheet. Then, click the three-dot menu โ†’ Share & export โ†’ Save as โ†’ CSV. But Apps Script are only available on desktop.


Concluding Words

In this article, we learned how to save Google Sheets as CSV using four different ways. Download as CSV, publish to the web, Export using Google App Script and copy-paste into a text editor. Feel free to give us suggestions and feedback regarding this article.

Facebook
X
LinkedIn
WhatsApp
Picture of Nusrat Jahan

Nusrat Jahan

Nusrat Jahan holds a BSc in Computer Science & Engineering from North South University and has 4+ years of Excel and Google Sheets experience. She specializes in data analysis, visualization, formulas, PivotTables, charts, data cleaning, validation, and IMPORTRANGE. She enjoys creating habit trackers, budget planners, and project management sheets, using formulas, conditional formatting, and interactive tools to simplify task organization and financial planning.
We will be happy to hear your thoughts

Leave a reply


Excel Insider
Logo