# Store Credit Import From File

The **Store Credit Import from File** feature allows you to bulk add store credit to customer accounts using a CSV file. This powerful tool enables you to credit multiple customers at once, set expiry dates, specify currencies, and automatically send notifications to customers.

### When to Use This Feature

* **Bulk Refunds**: Issue store credit to multiple customers at once
* **Loyalty Rewards**: Credit loyal customers as part of a rewards program
* **Compensation**: Quickly compensate customers for order issues
* **Promotional Credits**: Launch promotional campaigns with store credit incentives
* **Account Migrations**: Transfer credit balances from external systems
* **Seasonal Campaigns**: Set up time-limited store credit offers

### Getting Started

#### Step 1: Prepare Your CSV File

Download one of our templates to get started:

* Simple Template - Basic store credit with email
* Advanced Template - All available options

{% file src="<https://2895247924-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FcsKliv3CuXU7kN4gxX9B%2Fuploads%2FH40xeRu1hv3NttoHmZPO%2Fstore_credit_simple_template.csv?alt=media&token=14cc82e2-66cb-4139-9e68-379736b4fb33>" %}

{% file src="<https://2895247924-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FcsKliv3CuXU7kN4gxX9B%2Fuploads%2FKKEWcxREvbDQGWgmvimL%2Fstore_credit_advanced_template.csv?alt=media&token=c099fa85-2229-494d-bdf0-603bbe8b7519>" %}

#### Step 2: Fill in Your Data

Edit the CSV file with your store credit data. See the **Column Reference** below for details on each field.

#### Step 3: Upload and Import

1. Navigate to **Bulk Operations** → **New Bulk Operation**
2. Select **Store Credit** tab
3. Click **Import From File**
4. Upload your CSV file
5. Review any validation errors
6. Configure email sending (optional)
7. Click **Import now** or **Schedule** for later

### CSV Column Reference

#### Required Columns

These columns **must** be present in your CSV file:

| Column                   | Description                                 | Format                    | Example                               |
| ------------------------ | ------------------------------------------- | ------------------------- | ------------------------------------- |
| `amount`                 | Amount of store credit to add               | Decimal number (positive) | `25.00` or `25`                       |
| `email` or `customer_id` | Customer identifier (at least one required) | Valid email or numeric ID | `customer@example.com` or `123456789` |

#### Optional Columns

Add these columns to customize your store credits:

| Column          | Description                                | Format                   | Example             |
| --------------- | ------------------------------------------ | ------------------------ | ------------------- |
| `customer_id`   | Shopify customer ID (alternative to email) | Numeric ID               | `123456789`         |
| `currency_code` | Currency code for the credit amount        | 3-letter ISO code        | `USD`, `EUR`, `GBP` |
| `expires_at`    | Expiration date for the store credit       | YYYY-MM-DD or DD/MM/YYYY | `2027-12-31`        |

#### Column Details

**`amount` (Required)**

* Must be a positive number
* Can use decimal points (`.`) or commas (`,`) as decimal separators
* The system will automatically convert commas to dots
* Examples: `25`, `25.00`, `25,50` (becomes 25.50)

**`email` or `customer_id` (At least one required)**

* **email**: Must be a valid email address. The system will look up or create a customer with this email
* **customer\_id**: The Shopify customer ID. If provided along with email, customer\_id takes precedence
* If the customer doesn't exist and only email is provided, a new customer account will be created

**`currency_code` (Optional)**

* Must be a valid 3-letter ISO 4217 currency code
* If not provided, uses your shop's default currency
* Must match one of the currencies enabled in your Shopify store
* Common codes: `USD`, `EUR`, `GBP`, `CAD`, `AUD`, `JPY`

**`expires_at` (Optional)**

* Store credit will expire on this date
* If not provided, store credit never expires
* Accepts multiple date formats (see below)

**Supported Date Formats:**

* `YYYY-MM-DD` (recommended): `2027-12-25`
* `DD/MM/YYYY`: `25/12/2027`
* `MM/DD/YYYY`: `12/25/2027`
* `DD-MM-YYYY`: `25-12-2027`
* `MM-DD-YYYY`: `12-25-2027`

**Note:** If your file contains ambiguous dates (like `01/05/2027`), you'll be asked to specify if the first number represents day or month.

### Examples

#### Example 1: Simple Store Credit

Add store credit to customers with just amounts and emails:

```csv
amount,email
25.00,customer1@example.com
50.00,customer2@example.com
10.00,customer3@example.com
```

#### Example 2: Store Credit with Expiry

Set expiration dates for promotional credits:

```csv
amount,email,expires_at
25.00,customer1@example.com,2027-12-31
50.00,customer2@example.com,2027-06-30
10.00,customer3@example.com,2027-03-31
```

#### Example 3: Multi-Currency Store Credit

Specify different currencies for international customers:

```csv
amount,email,currency_code,expires_at
25.00,us-customer@example.com,USD,2027-12-31
20.00,uk-customer@example.com,GBP,2027-12-31
30.00,eu-customer@example.com,EUR,2027-12-31
```

#### Example 4: Using Customer IDs

Use Shopify customer IDs instead of email addresses:

```csv
amount,customer_id,currency_code
25.00,123456789,USD
50.00,987654321,USD
10.00,555555555,USD
```

#### Example 5: Mixed Approach

Combine email and customer ID for flexibility:

```csv
amount,email,customer_id,currency_code,expires_at
25.00,customer1@example.com,,,2027-12-31
50.00,,987654321,USD,2027-06-30
10.00,customer3@example.com,,EUR,
```

**Note:** Leave columns empty when not needed (use consecutive commas).

### Customer Creation & Lookup

#### How the System Identifies Customers

1. **If `customer_id` is provided**: The system uses this ID to look up the customer in Shopify
2. **If only `email` is provided**: The system searches for a customer with this email
3. **If customer doesn't exist** (email only): A new customer account is automatically created with that email

#### Important Notes on Customer Creation

* New customers created during import will receive a "Welcome" email from Shopify (if enabled in your store settings)
* If you're importing for existing customers, consider using `customer_id` to avoid potential duplicate accounts
* Email addresses must be unique per customer in Shopify

### Email Notifications

You can optionally send email notifications to customers when store credit is added to their account.

#### Enabling Notifications

1. In the import form, check **"Send store credit notifications to customers"**
2. Your CSV must include either `email` or `customer_id` columns
3. Select an email sender (Klaviyo, SendGrid, Mailchimp, or Store Email)
4. Choose or customize an email template

#### Email Template Variables

When composing your notification email, you can use these variables:

* `{{store_credit_amount}}` - The amount of credit added
* `{{store_credit_currency}}` - Currency code (e.g., USD)
* `{{store_credit_expires_at}}` - Expiration date (if set)
* `{{customer_first_name}}` - Customer's first name
* `{{customer_last_name}}` - Customer's last name
* `{{shop_name}}` - Your store name

#### Example Email Template

```
Hi {{customer_first_name}},

Great news! We've added {{store_credit_amount}} {{store_credit_currency}} to your account.

You can use this credit on your next purchase at {{shop_name}}.

{{#if store_credit_expires_at}}
Please note: This credit expires on {{store_credit_expires_at}}.
{{/if}}

Happy shopping!
```

### Scheduling Store Credit

You can schedule store credit to be added at a future date using the **scheduled\_on** column.

#### How It Works

Add a `scheduled_on` column to your CSV with dates when each credit should be processed:

```csv
amount,email,scheduled_on
25.00,customer1@example.com,2026-02-01
50.00,customer2@example.com,2026-03-01
10.00,customer3@example.com,2026-04-01
```

The system will automatically:

1. Group credits by scheduled date
2. Create separate import jobs for each date
3. Execute each job on its scheduled date

#### Scheduling Notes

* `scheduled_on` accepts the same date formats as `expires_at`
* You can mix scheduled and immediate imports in the same file
* Rows without `scheduled_on` are processed immediately (or on the date/time you select in the form)
* Scheduled jobs appear in your Bulk Operations list with "Scheduled" status

### Best Practices

#### 1. Start Small

Test with a CSV file containing 5-10 customers to ensure everything is configured correctly before importing hundreds or thousands of credits.

#### 2. Use Clear Amount Formatting

* Always include decimal places for clarity: `25.00` instead of `25`
* Use consistent decimal separators throughout your file
* Avoid currency symbols ($, €, £) in the amount column

#### 3. Set Appropriate Expiry Dates

Consider your business goals:

* **Promotional Credits**: Set expiry dates 3-6 months out to create urgency
* **Refund Credits**: Consider no expiry or 12+ months
* **Loyalty Rewards**: Align with your loyalty program terms

#### 4. Choose the Right Currency

* Multi-currency stores: Always specify `currency_code` to avoid confusion
* Single currency stores: Currency code is optional (defaults to shop currency)
* Ensure the currency is enabled in your Shopify payments settings

#### 5. Validate Customer Information

* For existing customers: Use `customer_id` when possible for accuracy
* For new customers: Verify email addresses are correct
* Clean your email list to avoid bounces and failed deliveries

#### 6. Plan Email Notifications

* Write clear, friendly notification messages
* Test email templates with sample data before bulk import
* Consider timing: Don't send thousands of emails during peak hours
* Include clear instructions on how to use store credit

#### 7. Keep Records

* Save your CSV files for audit purposes
* Include a reference column (like order number or campaign name) for tracking
* Export store credit balances from Shopify before and after large imports

### Common Use Cases

#### Use Case 1: Holiday Loyalty Program

Reward loyal customers with store credit during the holidays:

```csv
amount,email,expires_at
50.00,loyal-customer-1@example.com,2027-01-31
50.00,loyal-customer-2@example.com,2027-01-31
50.00,loyal-customer-3@example.com,2027-01-31
```

#### Use Case 2: Order Issue Compensation

Quickly compensate multiple customers for shipping delays:

```csv
amount,customer_id,email
10.00,123456789,customer1@example.com
10.00,987654321,customer2@example.com
10.00,555555555,customer3@example.com
```

#### Use Case 3: Tiered Rewards Program

Issue different credit amounts based on customer tiers:

```csv
amount,email,expires_at
25.00,silver-customer@example.com,2027-12-31
50.00,gold-customer@example.com,2027-12-31
100.00,platinum-customer@example.com,2027-12-31
```

#### Use Case 4: Referral Program Credits

Credit customers who referred friends:

```csv
amount,email,scheduled_on
15.00,referrer1@example.com,2026-02-01
15.00,referrer2@example.com,2026-02-01
15.00,referrer3@example.com,2026-02-01
```

#### Use Case 5: Store Migration

Transfer store credit balances from your old system:

```csv
amount,email,currency_code,expires_at
125.50,old-customer-1@example.com,USD,2027-12-31
75.00,old-customer-2@example.com,USD,2027-12-31
200.00,old-customer-3@example.com,USD,2027-12-31
```

### Troubleshooting

#### Issue: Import fails with "No file uploaded"

**Solution:** Make sure you've selected a CSV file and the file is not corrupted. Try re-saving the CSV from your spreadsheet application.

#### Issue: "Row X: amount is required"

**Solution:** Every row must have an amount. Check that the `amount` column is filled in for all rows and contains valid numbers.

#### Issue: "Row X: email or customer\_id is required"

**Solution:** Each row must have either an email address or a customer\_id. Fill in at least one of these columns.

#### Issue: "Row X: amount must be a positive number"

**Solution:** Store credit amounts cannot be negative or zero. Use positive numbers only.

#### Issue: "Row X: currency\_code 'XYZ' is not valid"

**Solution:** The currency code must be a valid 3-letter ISO code (e.g., USD, EUR, GBP). Check the currency is enabled in your Shopify store.

#### Issue: "Row X: customer not found"

**Solution:** If using `customer_id`, verify the ID exists in Shopify. If using `email`, the system will create a new customer (this is normal behavior).

#### Issue: Dates are interpreted incorrectly

**Solution:** Use the YYYY-MM-DD format (e.g., `2027-12-25`) or specify your date format when prompted during import.

#### Issue: Credits not sent to customers

**Solution:**

1. Check that "Send store credit notifications" is enabled in the import form
2. Verify email addresses or customer IDs are valid
3. Ensure you've selected an email sender and template
4. Check your email service (Klaviyo, SendGrid, etc.) is properly configured

#### Issue: Decimal amounts are wrong

**Solution:** Ensure you're using a dot (`.`) as the decimal separator, not a comma. The system converts commas automatically, but it's best to use dots for clarity.

### Limitations

* **Maximum File Size**: 10MB per CSV file
* **Processing Time**: Large imports (10,000+ rows) may take several minutes
* **Currency Restrictions**: Currency must be enabled in your Shopify store settings
* **Customer Creation**: Only basic customer information (email) is set for new customers
* **No Partial Credits**: Amount is added once per row; cannot schedule recurring credits in a single import

### Additional Resources

* [Store Credit Bulk Add](https://docs.giftcardfactory.app/bulk-operations/store-credit-bulk-add) - For adding credit to customer lists
* [Email Templates](https://docs.giftcardfactory.app/email-templates) - Customize notification emails
* [Shopify Store Credit](https://help.shopify.com/en/manual/customers/store-credit) - Official Shopify documentation

### Need Help?

If you have questions or need assistance:

* Check our [FAQ](https://docs.giftcardfactory.app/faq)
* Contact support via email or in-app chat
* Join our community forum for tips and best practices

***

*Last updated: January 2026*
