---
title: "Replace a Wiki"
method: PUT
path: "/wikis/{wiki_id}/"
tags: ["Wikis"]
---

# Replace a Wiki

`PUT /wikis/{wiki_id}/`

Renames the specified wiki page by setting its `name` attribute. This is the only attribute that can be changed through this endpoint; to update the content of a wiki page, create a new wiki version instead.
Wiki pages can be updated with either a **PUT** or **PATCH** request. Unlike **PATCH**, a **PUT** request must include the `name` attribute in the request body.

The `home` wiki page cannot be renamed.
#### Permissions
Only contributors with write access to the parent node may rename a wiki page (or any user, if the node's wiki has been made publicly editable). Wiki pages on registrations cannot be renamed.
#### Returns
Returns a JSON object with a `data` key containing the new representation of the updated wiki, if the request is successful.

If the request is unsuccessful, an `errors` key containing information about the failure will be returned. Refer to the [list of error codes](#tag/Errors-and-Error-Codes) to understand why this request may have failed.
Some common error cases:
 - `405 Method Not Allowed`: Returned if write access to this wiki's node has been restricted. The response will include the message "This action is no longer available. Contact support if you have any questions."

## Path parameters

- `wiki_id` string, required

## Request body

- object

## Response `200`

OK

## Other responses

- `405` — Returned if write access to this wiki's node has been restricted. The response will include the message "This action is no longer available. Contact support if you have any questions."

---

[API](https://skmtc.net/osf/apis/osf-apiv2-documentation.md) · [All operations](https://skmtc.net/osf/apis/osf-apiv2-documentation/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/osf/osf-apiv2-documentation/revisions/3c5164c707eb/schema)
