---
name: walletlock
btcversion: 0.16.3
btcgroup: wallet
permalink: en/doc/0.16.3/rpc/wallet/walletlock/
---

walletlock

Removes the wallet encryption key from memory, locking the wallet.
After calling this method, you will need to call walletpassphrase again
before being able to call any methods which require the wallet to be unlocked.

Examples:

Set the passphrase for 2 minutes to perform a transaction
> bitcoin-cli walletpassphrase "my pass phrase" 120

Perform a send (requires passphrase set)
> bitcoi