PUT - Update/Replace Resource in HTTP
From the HTTP Methods cheat sheet ยท CRUD Methods ยท verified Jul 2026
PUT - Update/Replace Resource
javascript
// PUT request
fetch('/api/users/123', {
method: 'PUT',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify(completeData)
})
// Properties
- Safe: No
- Idempotent: Yes
- Cacheable: No
- Body: Yes๐ Replaces entire resource
โ
Idempotent - same request produces same result
๐ Requires complete resource representation