{"id":15041131,"url":"https://github.com/neondatabase/pg-import","last_synced_at":"2025-07-18T18:31:54.737Z","repository":{"id":241674926,"uuid":"806408231","full_name":"neondatabase/pg-import","owner":"neondatabase","description":"A CLI tool for importing data from one PostgreSQL database to another.","archived":false,"fork":false,"pushed_at":"2024-06-03T19:07:06.000Z","size":106,"stargazers_count":9,"open_issues_count":0,"forks_count":0,"subscribers_count":7,"default_branch":"main","last_synced_at":"2025-07-18T12:56:55.688Z","etag":null,"topics":["backup","database-import","databases","libpq","postgres","postgres-migration","postgresql"],"latest_commit_sha":null,"homepage":"https://npmjs.com/package/@neondatabase/pg-import","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/neondatabase.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-05-27T06:31:20.000Z","updated_at":"2025-05-16T14:49:36.000Z","dependencies_parsed_at":"2025-04-14T19:43:56.134Z","dependency_job_id":"691a3f0a-5c99-4501-9295-a8cb6887a24b","html_url":"https://github.com/neondatabase/pg-import","commit_stats":null,"previous_names":["neondatabase/pg-import"],"tags_count":8,"template":false,"template_full_name":null,"purl":"pkg:github/neondatabase/pg-import","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neondatabase%2Fpg-import","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neondatabase%2Fpg-import/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neondatabase%2Fpg-import/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neondatabase%2Fpg-import/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/neondatabase","download_url":"https://codeload.github.com/neondatabase/pg-import/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neondatabase%2Fpg-import/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265809978,"owners_count":23831944,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["backup","database-import","databases","libpq","postgres","postgres-migration","postgresql"],"created_at":"2024-09-24T20:45:38.342Z","updated_at":"2025-07-18T18:31:54.696Z","avatar_url":"https://github.com/neondatabase.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Migrate between Postgres databases\n\nA CLI tool for **migrating data from one PostgreSQL database to another**.\n\n\u003e [!NOTE]  \n\u003e **This project is experimental.**\n\u003e \n\u003e There may be bugs, and the API is subject to change. While we cannot provide professional support for experimental projects, we welcome your feedback.\n\n## Usage\n\n```sh\nnpx @neondatabase/pg-import@latest --silent false --accept-all false --source=\"pg-string\" --destination=\"pg-string\"\n```\n\n### Flags and Options\n\n- `--source \u003csource\u003e`: The connection string for the source PostgreSQL database. This is **optional**.\n  - Example: `--source \"postgres://user:password@localhost:5432/source_db\"`\n\n- `--destination \u003cdestination\u003e`: The connection string for the destination PostgreSQL database. This is **optional**.\n  - Example: `--destination \"postgres://user:password@localhost:5432/destination_db\"`\n\n- `--silent`: Suppresses console output if set to `true`. The default value is `false`.\n  - Example: `--silent true`\n\n- `--accept-all`: Automatically accepts all prompts if set to `true`. The default value is `false`.\n  - Example: `--accept-all true`\n\n- `--backup-file-path`: Specifies the path and filename for the backup file. If not set, the default value is **dump_restore_{randomly_generated_string}.bak**.\n  - Example: `--backup-file-path \"../Downloads/example.bak\"`\n\n## When Migrating to Neon\n\n- Make sure your Neon plan supports your database size. The Neon Free Tier offers 0.5 GiB of storage. For larger data sizes, upgrade to the Launch or Scale plan. See [Neon plans](https://neon.tech/docs/introduction/plans).\n- If you are on the Neon Launch or Scale plan, you can optimize for the migration by configuring a larger compute size or enabling [autoscaling](https://neon.tech/docs/introduction/autoscaling) for additional CPU and RAM. See [How to size your compute](https://neon.tech/docs/manage/endpoints#how-to-size-your-compute).\n- This utility uses `pg_dump` and `pg_restore`. A generated dump file containing any of the following statements will produce a warning or error when data is restored to Neon:\n  - `ALTER OWNER` statements\n  - `CREATE EVENT TRIGGER` statements\n  - Any statement requiring the PostgreSQL superuser privilege or not held by the role running the migration\n\n  See [Import from Postgres](https://neon.tech/docs/import/import-from-postgres) for possible workarounds.\n\n## Authors\n\nThis library is created by [Neon](https://neon.tech) with contributions from:\n\n- Rishi Raj Jain ([@rishi_raj_jain_](https://twitter.com/rishi_raj_jain_))\n\n## Contributing\n\nWe love contributions! Here's how you can contribute:\n\n- [Open an issue](https://github.com/neondatabase/pg-import/issues) if you believe you've encountered a bug.\n- Make a [pull request](https://github.com/neondatabase/pg-import/pull) to add new features, make improvements, or fix bugs.\n\n## Contributors\n\n\u003ca href=\"https://github.com/neondatabase/pg-import/graphs/contributors\"\u003e\n  \u003cimg src=\"https://contrib.rocks/image?repo=neondatabase/pg-import\u0026purge=1\" /\u003e\n\u003c/a\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fneondatabase%2Fpg-import","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fneondatabase%2Fpg-import","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fneondatabase%2Fpg-import/lists"}