---
title: "Set volume read-only"
method: PUT
path: "/volumes/{id}"
tags: ["volumes"]
---

# Set volume read-only

`PUT /volumes/{id}`

Updates a volume's read-only status.

## Path parameters

- `id` integer, required

## Request body

- UpdateVolumeRequest
  - `readOnly` boolean, required — Whether the volume should be read-only. A read-only volume will not accept new sectors.

## Response `200`

Volume updated.

---

[API](https://skmtc.dev/siafoundation/apis/hostd-api.md) · [All operations](https://skmtc.dev/siafoundation/apis/hostd-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/siafoundation/hostd-api/revisions/08ff756929fc/schema)
