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

# Remove Member (Controlled Multisig)

## Overview

Remove a member via Config Authority. This instruction allows the config authority to remove members without going through the standard proposal process.

<Note>
  Can only be used with a [Controlled Multisig](/developers/reference/controlled-multisigs).
</Note>

## Prerequisites

* Multisig with Config Authority set
* `@sqds/multisig` package installed
* Config Authority signer

## Quick Example

```typescript theme={null}
import * as multisig from "@sqds/multisig";
import { Connection, Keypair, PublicKey } from "@solana/web3.js";

await multisig.rpc.multisigRemoveMember({
  connection,
  feePayer,
  multisigPda,
  configAuthority: configAuthority.publicKey,
  oldMember,
  signers: [configAuthority],
  memo,
  programId,
});
```

## Parameters

| Parameter | Type | Required | Description |
| - | - | - | - |
| `connection` | `Connection` | Yes | Solana RPC connection |
| `feePayer` | `Keypair` | Yes | Transaction fee payer |
| `multisigPda` | `PublicKey` | Yes | PDA of the multisig |
| `configAuthority` | `PublicKey` | Yes | Config authority public key |
| `oldMember` | `PublicKey` | Yes | Public key of member to remove |
| `signers` | `Signer[]` | No | Additional signers. Pass the config authority here so it signs the transaction |
| `memo` | `string` | No | Optional memo |
| `programId` | `PublicKey` | No | Squads program ID |

## Full Example

```typescript theme={null}
import * as multisig from "@sqds/multisig";

// Cluster Connection
const connection = new Connection("<your rpc url>");

// Fee payer is the a signer that pays the transaction fees
const feePayer = Keypair.generate();
// Replace with the keypair of the multisig's config authority
const configAuthority = Keypair.generate();

// Derive the multisig PDA
const multisigPda = multisig.getMultisigPda({
    // The createKey has to be a Public Key, see accounts reference for more info
    createKey,
})[0];

// Public Key of the old member
const oldMember = new PublicKey("");

await multisig.rpc.multisigRemoveMember({
    connection,
    feePayer,
    // The public key of the multisig account
    multisigPda,
    // Public Key of the config authority of the multisig
    configAuthority: configAuthority.publicKey,
    oldMember,
    // The config authority must sign the transaction
    signers: [configAuthority],
    memo,
    // ProgramId of the Squads Program
    programId

});
```

## Error Handling

| Error | Cause | Solution |
| - | - | - |
| Invalid config authority | Wrong or missing config authority | Verify config authority is set on multisig |
| Not a controlled multisig | Multisig has no config authority | Use Config Transaction instead |
| Member not found | Member does not exist in multisig | Verify member public key |

## See Also

* [Controlled Multisigs Reference](/developers/reference/controlled-multisigs)
* [Add Member](/developers/typescript-sdk/instructions/controlled-multisig/add-member)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.