How to rename components in SketchUp, one or hundreds
To rename a component in SketchUp, select one copy and type a new name in the Definition field of Entity Info: every copy changes, because they share one definition. To label just one copy, use the Instance field instead. To rename hundreds at once, use an extension or a short Ruby script.
Definition name vs instance name
Every component has two names, and most renaming confusion comes from mixing them up.
- Definition name: the component's own name, shared by every copy. It is what the Components panel lists under In Model and what most reports and cut lists count by. It must be unique in the model.
- Instance name: an optional label on one placed copy, such as "front left leg" on one of four identical legs. It is blank by default, and several copies can share one.
Select a component and open Entity Info (in the Default Tray on Windows, Window › Entity Info on macOS). It shows both: Instance for the copy you selected and Definition for the shared name. The Outliner shows them together as Instance name <Definition name>.
Groups are simpler. A group has only the one name you give it, and the Outliner shows plain "Group" until you do.
How to rename a component
There are three places to do it.
- Entity Info: select a copy, type in Definition to rename the component everywhere, or in Instance to label this copy. Press Enter to commit the name before you click anything else.
- Components panel: under In Model, select the component; its name and description at the top of the panel can be edited. This renames the definition. On Windows the panel is in the Default Tray; on macOS use Window › Components.
- Outliner: context-click or triple-click an entry, choose Rename, type the name and press Enter. For a component this sets the instance name, not the definition, which is why the result can read
New name <Old name>. Change the definition in Entity Info.
To rename a group, use the Outliner or the name field in Entity Info. If one copy of a component needs a different name because it really is a different part, right-click it and choose Make Unique first; SketchUp gives it a new definition with a number on the end, which you can then rename.
Renaming a definition inside the model does not rename a component file you saved to disk earlier. Save it again if your library should match.
Naming conventions that pay off later
Names are how you find things in the Outliner, how cut lists and reports group parts, and what exports carry into other software such as IFC viewers. A few habits help:
- Name the definition after what the part is, like
Shelf 600x300orEXT-WALL-01, notComponent#14. - Put the category first so related parts sort together in the panel and in reports:
DOOR-,WIN-,STUD-. - Use instance names for position or role, like "left" and "right", and keep the definition name for the part itself.
- Keep numbers padded (
01,02, then10) so lists sort in order.
If you build cut lists from the model, the definition name is usually the part name on the list. See how to make a cut list from a SketchUp model. For when a part should be a component at all, see Lookover's groups vs components guide.
Batch rename components with an extension
SketchUp has no built-in batch rename. Two routes exist outside the core app:
- Number Components by McGordon on SketchUcation numbers selected groups and components. Its Rename Component option writes the number into each copy's instance name (not the definition name), and it can also place 3D text labels.
- A short Ruby script, below, renames definitions to any pattern you like. It is free, and you can change the rule every time.
Check any extension's page for your SketchUp version before installing. Several older forum scripts rename only the top level of the model, and skip components nested inside others.
Rename components by pattern with Ruby
This renames every component definition whose name starts with wall_ to EXT-WALL-01, EXT-WALL-02 and so on, in alphabetical order. Paste it into Extensions › Developer › Ruby Console (Window › Ruby Console before SketchUp 2021.1) and press Enter. It is one undo step. New to the console? See how to run a Ruby script in SketchUp.
model = Sketchup.active_model
defs = model.definitions.to_a.select do |d|
!d.group? && !d.image? && d.name.start_with?("wall_")
end
model.start_operation("Rename wall components", true)
begin
defs.sort_by(&:name).each_with_index do |d, i|
d.name = format("EXT-WALL-%02d", i + 1)
end
model.commit_operation
puts "Renamed #{defs.size} components"
rescue => e
model.abort_operation
raise e
endIt works on definitions, so nested components are included and every copy of each one picks up the new name. Groups and images are skipped. Definition names must be unique, so if EXT-WALL-01 already exists SketchUp adds a suffix to the new one instead of failing; check the result in the Components panel.
To set instance names instead, loop over d.instances and set each one's name. To match by tag, size or position, change the select test. Describing rules like these to a chatbot is a fair way to get the script written; see using ChatGPT to write SketchUp Ruby.
Rename to a pattern by asking
MakeIt4Me (our product) connects an AI agent on your computer (Claude, ChatGPT desktop, Cursor and others) to your open SketchUp model, so you can describe the rename instead of writing the loop:
"Rename every component matching wall_* to EXT-WALL-<index>."
The agent finds the matching components, writes and runs the Ruby, and reports what it renamed. Rules that are awkward to script by hand work too, like numbering walls by floor or naming parts by size. The whole rename is one labeled undo step, so Cmd+Z or Ctrl+Z puts every name back. Some rules take a second round of prompting, and your AI provider bills its usage separately. See it in the demo, or how it compares with pasting code from a chatbot.
Questions
Why did renaming in the Outliner give me a name with angle brackets?
The Outliner sets the instance name, and shows components as Instance <Definition>. To rename the component itself, change the Definition field in Entity Info.
Can two components have the same name?
Not two definitions: SketchUp keeps definition names unique and adds a suffix to a duplicate. Instance names can repeat freely.
Does renaming a component change every copy?
Renaming the definition does. Renaming an instance changes only that copy. Use Make Unique first if one copy is really a different part.
Why can't I edit the Definition field?
Locked components can't be renamed. Right-click and choose Unlock, then try again.