---
title: "Edit a wiki page"
method: PATCH
path: "/repos/{owner}/{repo}/wiki/page/{pageName}"
tags: ["repository"]
---

# Edit a wiki page

`PATCH /repos/{owner}/{repo}/wiki/page/{pageName}`

## Path parameters

- `owner` string, required
- `repo` string, required
- `pageName` string, required

## Request body

- CreateWikiPageOptions — CreateWikiPageOptions form for creating wiki
  - `content_base64` string — content must be base64 encoded
  - `message` string — optional commit message summarizing the change
  - `title` string — page title. leave empty to keep unchanged

## Response `200`

WikiPage

- WikiPage — WikiPage a wiki page
  - `commit_count` integer — The number of commits that modified this page
  - `content_base64` string — Page content, base64 encoded
  - `footer` string — The footer content for the wiki page
  - `html_url` string — The HTML URL to view the wiki page
  - `last_commit` WikiCommit — WikiCommit page commit/revision
    - `author` CommitUser
      - `date` string — Date is the commit date in string format
      - `email` string, email — Email is the person's email address
      - `name` string — Name is the person's name
    - `commiter` CommitUser
      - `date` string — Date is the commit date in string format
      - `email` string, email — Email is the person's email address
      - `name` string — Name is the person's name
    - `message` string — The commit message
    - `sha` string — The commit SHA hash
  - `sidebar` string — The sidebar content for the wiki page
  - `sub_url` string — The sub URL path for the wiki page
  - `title` string — The title of the wiki page

## Other responses

- `400` — APIError is error format response
- `403` — APIForbiddenError is a forbidden error response
- `404` — APINotFound is a not found empty response
- `423` — APIRepoArchivedError is an error that is raised when an archived repo should be modified

---

[API](https://skmtc.net/gitea/apis/gitea-api.md) · [All operations](https://skmtc.net/gitea/apis/gitea-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/gitea/gitea-api/revisions/350de506cefa/schema)
