> ## Documentation Index
> Fetch the complete documentation index at: https://docs.neynar.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Change Farcaster name

A user can change their offchain ENS name or Fname without affecting their account's history. This can be done at most once in 28 days.

<Warning>
  * Fnames may be revoked if you violate the [usage policy](/farcaster/learn/architecture/ens-names#offchain-ens-names-fnames).
  * Apps may lower your reputation if you change Fnames often.
</Warning>

### Requirements

* An ETH wallet that owns the account on OP Mainnet. No ETH is required.

### Change username

To transfer an Fname, e.g. `farcaster`, make a POST request to `/transfers` with the following body:

```yaml theme={"system"}
{
  "name": "farcaster", // Name to transfer
  "from": 123,  // FID to transfer from
  "to": 321, // FID to transfer to
  "fid": 123, // FID making the request (must match from)
  "owner": "0x...", // Custody address of FID making the request
  "timestamp": 1641234567,  // Current timestamp in seconds
  "signature": "0x..."  // EIP-712 signature signed by the custody address of the FID
}
```

To generate the EIP-712 signature, use the following code:

```js theme={"system"}
import { makeUserNameProofClaim, EIP712Signer } from '@farcaster/hub-nodejs';

const accountKey: EIP712Signer = undefined; // Account Key for the custody address (use appropriate subclass from hub-nodejs for ethers or viem)

const claim = makeUserNameProofClaim({
  name: 'farcaster',
  owner: '0x...',
  timestamp: Math.floor(Date.now() / 1000),
});
const signature = (
  await accountKey.signUserNameProofClaim(claim)
)._unsafeUnwrap();
```

Example request via curl:

```bash theme={"system"}
curl -X POST https://fnames.farcaster.xyz/transfers \
  -H "Content-Type: application/json" \
  -d \
'{"name": "farcaster", "owner": "0x...", "signature": "0x...", "from": 123, "to": 321, "timestamp": 1641234567, "fid": 123}'
```

See [here](/farcaster/reference/fname/api) for more details on the Fname registry API.
