# File as the Main Store: How to connect CSV

In addition to shopping carts and LitCommerce itself, the tool also supports connecting Main Stores using files like CSV or [Google Sheets](https://litcommerce.gitbook.io/litcommerce-helpdesk/marketplace-integration/supported-platforms/files/file-as-the-main-store-how-to-connect-google-sheets).

This article outlines the instructions for connecting a CSV File as the Main Store to your LitCommerce account.

## <mark style="color:$primary;">**Step 1: Select CSV File as the Main Store**</mark>

{% stepper %}
{% step %}
Log in to your LitCommerce account. If you don’t have one, sign up [HERE](https://app.litcommerce.com/login).

If this is your first setup, choose your desired LitCommerce app: **Marketplace Integration** or **Feed Management**.

<figure><img src="/files/Ud1mCyLt3j5thSIyU5D7" alt=""><figcaption></figcaption></figure>

{% hint style="success" %}
**If you select the Marketplace Integration app, choose "Your online store becomes the source of truth" and click `Next` to proceed.**
{% endhint %}

<figure><img src="/files/k47GctTscTLbKDZ2xEyf" alt=""><figcaption></figcaption></figure>

{% endstep %}

{% step %}
Locate the Files section, and click on `Add CSV File`.

<figure><img src="/files/vn21Av10nnX3jVf5pOAY" alt=""><figcaption></figcaption></figure>
{% endstep %}
{% endstepper %}

## <mark style="color:$primary;">**Step 2: Enter required information**</mark>

Once select CSV, you will need to complete the following stages to connect your Main Store.

{% stepper %}
{% step %}
Enter your Store Name and File Name.

<figure><img src="/files/TOoMgmcU0dBsHchzNuzl" alt=""><figcaption></figcaption></figure>

{% endstep %}

{% step %}
Select your Type of Import.

<figure><img src="/files/oqfOVYBxjF9P7XNE6hBX" alt=""><figcaption></figcaption></figure>

* **Add New & Update:** This option allows new product/data to be retrieved into our system, and updates existing data.

* **Update Only:** Only existing data in our system will be updated when selecting this option. New/non-existing data will be skipped.

{% endstep %}

{% step %}
Select your preferred Import Method from one of the two available options.

<details>

<summary><strong>CSV - URL Download</strong></summary>

<figure><img src="/files/0ttAwG0u8mlbLEt0StrI" alt=""><figcaption></figcaption></figure>

* Enter your file URL.

* Select your authentication method based on the access validation setup of your file - there are 4 options:
  * **No Authentication:** LitCommerce’s default authentication method for all URLs.
  * **Basic & Digest Authentication:** You need to provide the username and password for the entered file URL.
  * **Authentication header:** A token generated by the server that contains your file will need to be provided.
  * **Amazon S3:** Use this method when your file URL’s source is Amazon S3 - a cloud storage service provided by Amazon Web Services (AWS). You need to enter your AWS Access Key ID and AWS Secret Access Key.

{% hint style="info" %}
**If an authentication method is selected when the entered file URL does not require verification, LitCommerce can still process the file.**
{% endhint %}

</details>

<details>

<summary><strong>CSV - SFTP/FTP</strong></summary>

<figure><img src="/files/yTEckh7QKAlzwaHPZNpZ" alt=""><figcaption></figcaption></figure>

To proceed with the connection, please correctly enter the following information.

* **Host:** Enter the server address where the file is stored (can be a domain name or an IP address). For example: ftp.example.com or 192.168.1.100. Please do not include prefixes, such as http\://, https\://, ftp\://, sftp\://.

* **Directory Path:** The entered value should start with a /, which represents the root directory or a specific directory on the server. For example: /data/products.csv or /products.csv.

* **Username**.

* **Password**.

</details>
{% endstep %}
{% endstepper %}

## <mark style="color:$primary;">**Step 3: Test Connection**</mark>

<figure><img src="/files/WF6XOElLil8FemyQxGa6" alt=""><figcaption></figcaption></figure>

Once the required details are entered, click `Test Connection` for LitCommerce to check the readability of your file. From there, you will find the following information.

* **Encoding.**
* **Quoting.**
* **Delimiter.**

This information determines how your data will be stored and displayed in our system. LitCommerce will automatically detect and assign the suitable Encoding, Quoting, and Delimiter based on the CSV file data. You can still update them per your preference.

To proceed with the next step, please click `Next`.

## <mark style="color:$primary;">**Step 4: Fields mapping**</mark>

After clicking `Next`, the interface for mapping your file fields to the LitCommerce fields will appear.&#x20;

Mapping refers to the essential process of connecting data fields between your Main Store and LitCommerce so that product information flows correctly to our system and the sales channels.

<figure><img src="/files/2eH7U679LDJ1meX2z0bT" alt=""><figcaption></figcaption></figure>

{% hint style="success" %}
**The AI-Field Mapping feature automatically maps your Main Store fields to the LitCommerce fields, even when they only have similar meanings or are in a different language. This helps you speed up the setup process.**
{% endhint %}

<figure><img src="/files/n3G9AkQvUPQcMPSMbgMA" alt=""><figcaption></figcaption></figure>

Here, you will see two field types:

* **Standard fields:** They are predefined by LitCommerce based on standard fields across platforms, ensuring key data is included when transferring data from the Main Store to the sales channels. LitCommerce will automatically map these fields to the matching fields in your file.

<figure><img src="/files/o9eP3UB6zpCVwcHQKJBu" alt=""><figcaption></figcaption></figure>

* **Custom fields:** These are a group of flexible data fields that you can add aside from the standardized fields. These fields are not required and can be used to store additional information depending on how you manage your data. The number of custom fields is unlimited, but will not be automatically transferred to the sales channels.

<figure><img src="/files/sVshmg3iYvNrVVe0rvmS" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}

* **The Product ID field is the primary key for identifying matching products between your file and LitCommerce. If multiple products share the same Product IDs, they will be considered as one item.**

* **The Parent SKU field is for grouping the variations under the correct parents. Skip this field if your products have simple format.**

* **The Images field helps retrieve your product images into our system. Each image URL must be placed in a separate column of your CSV file. This allows LitCommerce to import multiple images for your products.**
  {% endhint %}

Once all fields are mapped correctly, click `Save` to complete the connection process.

<figure><img src="/files/Sg1saclR2vT9Mqw0Z3Es" alt=""><figcaption></figcaption></figure>

If you have any questions, let us know via the Chat Box in the bottom-right corner of our Help Center.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.litcommerce.com/marketplace-integration/supported-platforms/files/file-as-the-main-store-how-to-connect-csv.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
