--- title: "Using Google Sheets and CSV files" slug: "using-csv-files" updated: 2026-03-05T00:49:27Z published: 2026-03-05T00:49:27Z canonical: "docs.preset.io/using-csv-files" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.preset.io/llms.txt > Use this file to discover all available pages before exploring further. # Using CSV files 👤 This documentation is intended for [Secondary Creators](/v1/docs/role-based-access-security-rbac) and above. ## Introduction Typically, Workspace Administrators would first connect organization's databases before team membmers start using Preset. However, [Primary Creators and Secondary Creators](/v1/docs/role-based-access-security-rbac) can still create datasets, charts, and dashboards from CSV files before connecting databases. ## Connect a Database and Enable Uploads For workspaces created before April 13, 2023: If you created your workspaces before April 13, 2023, a CSV file cannot be uploaded without a database connection. Be sure to add your database first to make use of the CSV upload feature! In order for the database to accept the CSV, you need to enable data uploads. Data uploads will be enabled by default. If data uploading is disabled, follow the below steps. Start by navigating to the **Database Connections** link from your settings. ![Database connections.png](https://cdn.document360.io/4749ddf8-aa05-4f3f-80e1-07a5d2d0f137/Images/Documentation/Database%20connections.png) and then select the **Edit** pencil icon for your database. ![CSV - Edit.png](https://cdn.document360.io/4749ddf8-aa05-4f3f-80e1-07a5d2d0f137/Images/Documentation/CSV%20-%20Edit.png) The "Edit database" panel appears. Select the **Advanced** tab and then expand the **Security** panel. In the **Schemas Allowed for CSV Upload** field, enter the name(s) of any schemas in your database that should be available for CSV data uploads. If more than one, separate each by a comma. In the **Allow data upload** field, select the checkbox. ![Allow data upload .png](https://cdn.document360.io/4749ddf8-aa05-4f3f-80e1-07a5d2d0f137/Images/Documentation/Allow%20data%20upload%20.png) If there are specific schemas to house the CSV upload, specify those schemas in the text box shown. Lastly, select **Finish**. To confirm, in the Databases screen under the "CSV upload" column header, ensure that a checkmark is displayed for your database row entry. In the example below, CSV data upload has been enabled. ![CSV data upload view.png](https://cdn.document360.io/4749ddf8-aa05-4f3f-80e1-07a5d2d0f137/Images/Documentation/CSV%20data%20upload%20view.png) ## Configure the CSV Upload In the Toolbar, select **Upload file to database**, and then, in the sub-menu, select **Upload CSV**. ![Upload CSV.png](https://cdn.document360.io/4749ddf8-aa05-4f3f-80e1-07a5d2d0f137/Images/Documentation/Upload%20CSV.png) Alternatively, you can hover your cursor over the plus **+** icon, then **Data**, and then select **Upload CSV to database** from any screen in Preset. ![Upload CSV file .png](https://cdn.document360.io/4749ddf8-aa05-4f3f-80e1-07a5d2d0f137/Images/Documentation/Upload%20CSV%20file%20.png) The "CSV to Database configuration" screen appears. ![Config.png](https://cdn.document360.io/4749ddf8-aa05-4f3f-80e1-07a5d2d0f137/Images/Documentation/Config.png) In the **CSV Upload*** field, select **Choose File** and select the CSV file on your local or network system. In the **Table Name*** field, enter a memorable name for the table to be created from the CSV data. In the **Database** field, select the database to use. In the **Schema** field, select the schema associated with the selected database. In the **Delimiter*** field, specify the symbol used to delimit the data. For a whitespace, use **\s+**. #### Other CSV Configurations #### File Settings ![File settings.png](https://cdn.document360.io/4749ddf8-aa05-4f3f-80e1-07a5d2d0f137/Images/Documentation/File%20settings.png) In the **Table Alerady Exists*** field, select what to do if a table already exists: **Fail** (do nothing), **Replace** (drop and recreate table), or **Append** (insert data). In the **Skip Initial Space** field, select to skip spaces after the delimiter. In the **Skip Blank Lines** field, select to skip blank lines instead of interpreting them as NaN values. In the **Columns To Be Parsed as Dates** field, add a comma-separated list of columns that should be parsed as dates. In the **Interpret Datetime Format Automatically** field, select to use Pandas to automatically interpret the datetime format. In the **Decimal Character** field, enter a character to interpret as a decimal point. In the **Index Column** field, enter the column to use as row labels for the data frame. Leave empty if there is no index column. In the **Mangle Duplicate Columns** field, select the checkbox to specify duplicate columns as "X.0, X.1". **Null Values**: List of values that should be treated as null, in JSON format. #### Columns ![Screenshot 2023-05-12 at 3.06.16 PM.png](https://cdn.document360.io/4749ddf8-aa05-4f3f-80e1-07a5d2d0f137/Images/Documentation/Screenshot%202023-05-12%20at%203.06.16%20PM.png) In the **Dataframe Index** field, select to write the dataframe index as a column, In the **Column Label(s)** field, enter one or more column labels for index columns. If none are provided and if Dataframe Index is true, then index names are used. #### Rows ![Screenshot 2023-05-12 at 3.06.23 PM.png](https://cdn.document360.io/4749ddf8-aa05-4f3f-80e1-07a5d2d0f137/Images/Documentation/Screenshot%202023-05-12%20at%203.06.23%20PM.png) In the **Header Row** field, enter 0 if your CSV data already has a header row or leave it empty if there is no header row present. In the **Rows to Read** field, enter the number of rows to read. In the **Skip Rows** field, enter the number of rows to skip at the start of the file. *: Required When done, select **Save**. After selecting **Save**, you will be taken to the "Datasets" screen where your newly-loaded CSV and associated dataset appear. ![files settings - save.png](https://cdn.document360.io/4749ddf8-aa05-4f3f-80e1-07a5d2d0f137/Images/Documentation/files%20settings%20-%20save.png) To learn morea bout datasets, visit [this page](/v1/docs/creating-datasets). ## Visualize the CSV Data From here, you can select the dataset to launch it on the Chart Builder page and proceed with configuring a chart. ![Visualize the CSV data.png](https://cdn.document360.io/4749ddf8-aa05-4f3f-80e1-07a5d2d0f137/Images/Documentation/Visualize%20the%20CSV%20data.png) ## Common Errors for CSV Uploads See [Google Sheets and CSVs](/v1/docs/google-sheets-and-csvs#common-errors-in-the-csv-upload)