MainspringGuides › Rename extension
macOS Guide

Rename a file's extension on Mac without confirmation

Updated August 2026 · 4 min read

Renaming a file's extension on a Mac has two small hurdles: you have to be able to see the extension, and Finder asks you to confirm every change. Get both out of the way once — turn on visible extensions and switch off the confirmation dialog — and editing a suffix becomes as quick as editing any other part of a filename.

First, make the extension visible

Finder hides most extensions by default, so a file that looks like invoice is really invoice.pdf — and you cannot rename an ending you cannot see. Turn extensions on:

  1. Open Finder → Settings (Cmd+,) and click Advanced.
  2. Turn on Show all filename extensions.

Now every file shows its suffix, and renaming behaves predictably. This is the same across macOS Ventura, Sonoma, and Sequoia.

Switch off the confirmation

In the same Advanced tab, uncheck Show warning before changing an extension. That is the dialog that reads "Are you sure you want to change the extension?" — with it off, your renames commit without a prompt. Prefer Terminal? One command does it:

# rename extensions without the confirmation
defaults write com.apple.finder FXEnableExtensionChangeWarning -bool false
killall Finder

# undo: restore the confirmation
defaults write com.apple.finder FXEnableExtensionChangeWarning -bool true
killall Finder

Rename just the suffix

With both settings in place, changing an extension is a normal rename — but there is a trick to editing only the part after the dot:

  1. Click the file once to select it, then press Return to open the name for editing.
  2. Finder highlights only the base name and leaves the extension unselected. Press the Right arrow then End, or click just after the dot, to place the cursor in the suffix.
  3. Edit the extension — say change .rtf to .txt — and press Return. No dialog appears.

If you ever do want to replace the entire name including the extension, press Cmd+A while editing to select all of it first.

Two toggles, zero Terminal

Showing extensions and silencing the rename warning are two of the Finder switches Mainspring exposes as labelled one-click toggles — reversible any time, part of 90+ hidden macOS settings.

Try Mainspring free →

Signed & notarized by Apple · 1-day free trial · $29 once

Renaming is not converting

Worth repeating even with the dialog off: changing .png to .jpg does not turn a PNG into a JPEG — it just relabels it, and picky apps will notice. Use rename for genuinely mislabelled files; for a real format change, use a converter. If a suffix ever looks wrong, Get Info shows the file's true kind regardless of its name.