Install SnowSQL, configure credentials, and run queries against your Snowflake account from macOS.
Running SnowSQL from your Mac lets you test SQL, automate data loads, and integrate Snowflake into scripts without relying on a browser UI.
Have a Snowflake account, macOS 12+, Homebrew, and network access to *.snowflakecomputing.com
. Ensure the account role can create databases and warehouses.
Run brew install --cask snowflake-snowsql
. Homebrew downloads the latest SnowSQL package, places binaries in /Applications/SnowSQL
, and adds the CLI to your PATH.
Create ~/.snowsql/config
with:[connections]accountname = xy12345.us-east-1username = dev_userwarehouse = DEV_WHrole = DEVELOPER
Store the password encrypted with snowsql -a xy12345 -u dev_user -p
.
Execute snowsql -q "SELECT CURRENT_VERSION();"
. A version string confirms that SnowSQL authenticated and reached the Snowflake cloud service.
Run the SQL in “Syntax” below or pipe a .sql
file into SnowSQL: snowsql -f setup_ecommerce.sql
. Tables appear in the left panel of the UI and via SHOW TABLES;
.
Stage CSVs in an S3 bucket, then: COPY INTO customers FROM @my_stage/customers.csv FILE_FORMAT=(TYPE=CSV, SKIP_HEADER=1);
. Repeat for other tables.
Use familiar ANSI-SQL: SELECT c.name, SUM(o.total_amount) AS lifetime_value FROM Customers c JOIN Orders o ON c.id=o.customer_id GROUP BY 1 ORDER BY 2 DESC;
Keep SnowSQL updated with brew upgrade snowflake-snowsql
. Store credentials in Keychain, use network policies for least-privilege, and script recurring tasks with cron or GitHub Actions.
Only the SnowSQL client and drivers run on your Mac; the Snowflake databases remain in the cloud.
Yes. Install the Snowflake Python connector (pip install snowflake-connector-python
) or JDBC driver and reuse the same account identifier.
Homebrew tracks new releases; run brew upgrade snowflake-snowsql
periodically to stay current.