Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Migrate Db Laravel Package

andrey-helldar/migrate-db

Laravel package for migrating data between database connections. Move tables and records from a source database to a target using configurable connections, making it useful for switching database engines or relocating an application.

View on GitHub
Deep Wiki
Context7

Easy data transfer from one database to another

Frequently asked questions about Migrate Db
How do I install andrey-helldar/migrate-db in a Laravel application?
Install it with Composer using composer require andrey-helldar/migrate-db. The service provider is registered automatically through Laravel package auto-discovery, so no manual provider entry in config/app.php is required. After installation, publish or edit the package config file to declare your migration paths, then run the package's Artisan commands. Pin the constraint (for example ^3.4) rather than floating so the next minor release is a deliberate upgrade decision.
How do I configure multiple migration paths with migrate-db?
All paths are declared in a single package config file, where you define any number of migration directories as an array. Each entry points at a folder containing standard Laravel migration files, so application, package, and module migrations stay in separate locations. Because the config is a plain array, you can add or reorder sets without touching service providers. Commit the config so every environment resolves the same path list.
Which Artisan commands does migrate-db add for migrating and rolling back?
The package ships dedicated Artisan commands for migrating, rolling back, and refreshing each configured migration set independently. That means you can advance one module's migrations without touching the application's own set. Exact command signatures depend on the installed version, so run php artisan list after installing and confirm the names in the package README before wiring them into deployment scripts.
Does migrate-db support Laravel 10, 11, 12 and 13?
Version 3.4.0 is an additive compatibility release whose only functional change is added Laravel 13 support, so existing Laravel 10 and 11 applications see no behavioural change. Because a widened illuminate/* constraint can mean constraint-only support rather than tested support, read the composer.json require range and confirm it stays bounded rather than opening to a wildcard. Verify the CI matrix actually executes against your target Laravel major before relying on it. Also check the minimum PHP version declared after the bump against your runtime fleet.
Can migrate-db keep package or module migrations separate from app migrations?
Yes, that isolation is the package's main purpose. Each directory you register in the config becomes its own migration set with its own migrate, rollback, and refresh commands. This is useful for monoliths with module folders, or for packages that ship migrations you do not want mixed into database/migrations. Isolation also makes it easier to reason about which set a failed migration belongs to during an incident.
Does migrate-db use Laravel's native migrations table and repository?
Yes, it is built on Laravel's native migration repository and behaviour rather than a parallel bookkeeping system. Migrations therefore land in the standard migrations table and follow the normal batch semantics for rollback. The practical consequence is that existing tooling, such as migrate:status style inspection and RefreshDatabase in tests, continues to see those records. It also means the usual rules about editing already-run migration files still apply.
Is migrate-db safe to run in production and does it need config publishing?
It uses Laravel's own migration engine, so the familiar precautions apply: back up the database before any refresh, since refresh drops and rebuilds tables. Publishing the config is enough to get started, and vendor asset re-publishing is not required when upgrading within 3.x. Treat the refresh command as destructive and reserve it for local or staging environments unless you have a verified restore path. Because it is a convenience utility, keep it at the leaf of your dependency graph with no inbound coupling.
How do I test migrations that live in custom directories?
Point the package config at your test migration paths and let your test suite run the package's migrate command against the test connection before the assertions execute. RefreshDatabase still works because the package writes to the standard migrations table. Run the full suite on your current Laravel version first, then on the target version, to isolate any regression caused by the upgrade. It is also worth asserting that rollback leaves the schema in the expected state for each set.
What are the alternatives to andrey-helldar/migrate-db?
Laravel itself lets you pass a path option to the migrate command, and a service provider can call loadMigrationsFrom to register extra directories. Those built-in options are enough when you have one extra path and no need for per-set rollback or refresh. Migrate-db is worth it when you manage several independently migrating sets and want them declared in one config with dedicated commands. Evaluate whether the abstraction earns its place versus the framework-native flags before adding a dependency.
Is andrey-helldar/migrate-db actively maintained and what is the upgrade risk?
It is a single-maintainer community package, which introduces a bus factor you should weigh for anything long-lived. The 3.x line has been drop-in across minors, so upgrades require no code or config changes, but the maintainer's cadence for new Laravel majors becomes your upgrade critical path if you track the framework closely. Check open issues for regressions introduced while adding newer Laravel support, and review the composer.lock diff with a dry run so only this package moves.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
robertmarney/lara-hierarchial-collections
simonschaufi/rule-doc-generator
emissaoja/emissaoja
blackbricksoftware/gravityforms-civicrm-form-processor
al-rahabi/fancy-crud
jinas/dhivatar-component
mltstephane/laravel-quality
bernskiold/laravel-talentlms
bernskioldmedia/laravel-form-architect
youbar/easy-crud
c-point-labs/laravel-hostyourai
dbravoan/dbcms-admin-theme-dbcms
dbravoan/dbcms-theme-db-cyber
dbravoan/dbcms-blocks-basic
dbravoan/dbcms-module-content-audit
dbravoan/dbcms-module-ai-assistant
paygate-to/paygate-php
padosoft/askmydocs-connector-base
defstudio/supercharged-carbon
bernskioldmedia/laravel-matomo