Skip to content
EasyToPaste

How to Share Database Credentials With a Contractor or Teammate

Sharing a database password, connection string or admin login? Chat and email leave it sitting in a message log forever. Here is a safer handoff.

EasyToPaste Team Published 5 min read
  • database credentials
  • devops
  • how-to
  • secure sharing

A database credential is one of the few secrets that is both highly sensitive and routinely necessary to hand to someone else: a contractor setting up a new service, a teammate restoring from a backup, a support engineer debugging a production issue. The password or connection string has to travel from one person’s head (or password manager) to another’s, and most teams default to whatever channel is already open — Slack, email, a shared doc.

That default is the problem. A chat message or email with a database password sits in that channel’s history indefinitely. Months later it is still there, searchable by anyone with access to the channel, anyone who inherits the account, or anyone who breaches it. The credential itself might get rotated eventually; the copy of it in last March’s email thread almost never does.

What makes this handoff different from most secrets

Database credentials carry two risks ordinary passwords don’t:

  1. Scope. A compromised database credential, especially an admin one, can expose or alter every row in the database — not just one account.
  2. Longevity of the copy. Unlike a one-time login code, nobody feels urgency to delete a database password from a chat thread, because it “still works” and deleting it feels risky. The stale copy outlives the reason it was sent.

That second point is why the channel matters more here than for almost any other secret. The credential needs to exist in exactly one place after you send it: the recipient’s own password manager or configuration, not a message log.

  1. Create a one-time link. Paste the password or full connection string into EasyToPaste. Your browser encrypts it with AES-256-GCM using the Web Crypto API before anything leaves the device — the decryption key lives in the link itself, after the #, which browsers never send to any server. The service stores only the ciphertext and cannot read the credential.
  2. Set the shortest expiry that still works. If the recipient is online now, use the shortest option. If they’re in another timezone, pick a window measured in hours, not days — not the 30-day maximum.
  3. Send the link through your normal channel, and separately confirm you sent it — a short message on another channel, or a quick call, so a surprise link can be told apart from a phishing attempt. The full pattern is covered in our guide on sending a secret to someone who isn’t deeply technical, and the same verification habit applies here even between two engineers.
  4. The recipient opens the link once. They see the credential, copy it into their own tool, and the stored copy is gone. There is nothing left to find in six months.
  5. Rotate the credential once the handoff is done, if it’s a production or admin-level login. The one-time link protected the transit. It did not make the static password itself permanently safe — nothing can, since the recipient now knows it too.

Scope the credential before you send it, if you can

The safest database handoff is one where the credential being shared isn’t powerful enough to matter much if it leaks. Before reaching for any sharing tool:

  • Create a dedicated user for the contractor or the specific task, with only the permissions the task needs (read-only for a reporting job, one schema for a migration, one table for a support ticket).
  • Avoid sharing the root or admin login at all when a scoped alternative exists. If it doesn’t, that’s worth fixing independently of how you send it.
  • Set an expiry on the account itself, where your database supports temporary users, so access ends even if nobody remembers to revoke it.

None of that is EasyToPaste’s job — it’s database administration — but it is the step that determines how much a single mis-sent link can actually cost.

What EasyToPaste can and can’t see

The service can see that a secret exists, its type and size, and when it was created — enough to run the product and enforce limits. It cannot see the content or the decryption key, which never leaves your browser in readable form. It keeps no read receipt: the record is deleted once the secret is read or it expires, so you can tell it’s gone, but not which of the two happened. The Security page has the full technical detail.

Common situations

Handing a database to a new contractor. Create a scoped user for them first if your database supports it. Send that credential, with a short expiry, confirmed on a second channel.

A teammate needs a production password during an incident. Speed matters more than usual here — send the link, confirm by voice or a quick message, and rotate the credential once the incident is resolved.

Restoring from a backup in a shared environment. If several people might need the same credential over time, a one-time link isn’t the right tool for repeat access — create a credential each of them can hold permanently and scoped appropriately, and use the link only for the initial handoff.

The short version

  • Don’t paste a database password or connection string into a chat or email thread — it stays there indefinitely.
  • Send it as an encrypted, self-destructing link with the shortest expiry that still works.
  • Confirm you sent it on a second channel before the recipient opens it.
  • Scope the credential to the task where your database allows it, rather than sharing a root login.
  • Rotate production or admin-level credentials once the handoff is done — the link protects the transit, not the password’s whole lifetime.

Create a one-time link for the next credential handoff and see what the recipient sees by opening it in a second browser window.

Common questions

Is it safe to send a database password over Slack or email?
No. Both keep a permanent, searchable, plaintext copy in every inbox and channel history the message touches, and most teams never go back and delete it. A one-time link deletes the record once it is read, so there is no plaintext copy sitting in an inbox to find later; the ciphertext itself can still outlive that deletion, unreadable without the decryption key we never hold — a small secret lives inside the record, so what remains is the database-backup window of up to 35 days, while a larger file is a separate encrypted object that a storage lifecycle rule clears about 38 days after it was created. See our piece on why Slack, email and WhatsApp are the wrong channel for secrets.
What should I do with the credential after the handoff?
Treat the handoff as temporary by design. Once the recipient confirms they have what they need, rotate the password or regenerate the connection string, especially for admin-level or production access. The one-time link protects the few minutes between creating and reading it; it does not make a static credential safe to keep forever.
Can I share a full connection string, not just a password?
Yes. A connection string is just text, so it goes into the same box as a password. Many connection strings also carry a hostname and database name, which is more than a password alone reveals, so prefer the shortest possible expiry and a scoped, revocable credential over the account's own root login.
What if the recipient needs the credential more than once?
A one-time link is for the handoff, not for storage. If a contractor needs standing access, create them their own database user with scoped permissions instead of a shared login. Use a one-time link for the one occasion you need to tell them what it is.

All articles