Please advise on simple, intuitive language for explaining a circular reference. I have a situation where adding children to a parent entity from the UI works just fine. I prevent circular references then tell the user the operation can't be completed in that situation. How to tell them why it's an error?

My current message is:

The operation could not be completed because it would cause the item to be added to itself either directly or indirectly.

Any better ideas?

GMail just offered up a nice example of the issue. ;)

Circular Reference

  • 26
    To explain circular references you must first explain circular references
    – Ben Brocka
    Commented Apr 11, 2012 at 14:45
  • 1
    Show them this video; it helps explain that circular references can be deadly.
    – zzzzBov
    Commented Apr 11, 2012 at 15:46
  • 1
    So they have to watch a video to understand a dialog?
    – Adam Grant
    Commented Apr 11, 2012 at 17:42
  • 3
    "You cannot do this. It would break the Universe."
    – f8xmulder
    Commented Apr 11, 2012 at 20:17
  • 3
    The circular reference is not the problem though - what the circular reference causes, or breaks, is the problem. Focus on that in your error message.
    – Erics
    Commented Apr 12, 2012 at 5:07

11 Answers 11


Could you maybe use some more clear text, tailored to the user's task? "The operation" -- does the user know what the operation is? Is this adding an item to a cart, organizing items into categories, etc? It could be clearer by describing the operation in the error message.

Also, perhaps you could change the veribage to be more particular to what your child/parent objects are. Users may not understand a parent/child relationship if it's not obvious to the context of the task they are performing.

  • 1
    +1 - I was just typing up something similar. Explicitly name the thing that cannot be done: "Cannot add Entity A because Detail B would make it a [sub-entity] of itself" where "sub-entity" is whatever your users call sub-entities. This way they'll know what they may need to do differently the next time.
    – Karen
    Commented Apr 11, 2012 at 14:50
  • I like this but there are multiple situations where this could happen so I was hoping I could explain it more generally. Two specific examples are: 1. adding a part to a list of subparts and 2. adding a task to a subtask.
    – xanadont
    Commented Apr 11, 2012 at 15:01
  • 7
    Generic messages are definitely easier to develop :) But specific messages might be more beneficial to the user.
    – Karen
    Commented Apr 11, 2012 at 15:09

State the problem, simply, then explain the problem - simply.


This action results in a circular reference.

A circular reference is where the action uses information that depends on the action itself.

Microsoft Excel kind of does this but in a typically verbose manner:

enter image description here

Although it may make sense to explicitly state what operation was invalid, it may be that the circle that forms the circular reference can have variable diameters, so to speak. In such cases it may be difficult, if not impossible, to either determine or explain what went wrong in terms that the user can sensibly understand and remember for future occasions.

In any case, the onus should not be on the user to have to analyse an action to determine the likelihood of producing a circular reference. Much better to state the problem simply, and thus make the user aware that such a thing can happen and in the process, assure them in a friendly manner that the product can detect the situation for them and prevent it from happening and that the user doesn't have to worry about it.

For more information, see this answer.

  • 9
    I see what you did there. ;)
    – xanadont
    Commented Apr 11, 2012 at 15:31
  • 12
    "Click cancel to continue." Ugh
    – bevacqua
    Commented Apr 11, 2012 at 20:40
  • 6
    Jeez, the text on that Excel dialog is all sorts of messed up. So... let me get this straight. The user did something dumb, and the computer pointed it out. Then somehow, OK means "submit to a mind-numbing lecture from the Big M about the evils of circular references, and Cancel means "Continue into the dark vortex of circular references"? What kind of evil green space magic is this?
    – rbwhitaker
    Commented Apr 11, 2012 at 23:29
  • 1
    Send them here: google.com/search?q=recursion Commented Apr 12, 2012 at 4:28
  • 1
    @rbwhitaker LoL, "Green space magic"... =) Commented Apr 12, 2012 at 14:44

Use a picture of Xzibit in the dialog. "Yo dawg...I heard you like operations, but you can't put operations in your operations because it would make you operate while you operate."

Okay maybe that won't work in a serious application. But using a metaphor would help.

"You cannot perform this operation because it would cause an object to contain itself."


Circular references are hard topic either to explain and to understand, so along with a message (sorry, this will make a cycle) consider adding some explanatory image. It could be small, very schematic, but it should really help your users to understand what the hell are you talking about:

enter image description here

  • 1
    Really smart idea. I like this!
    – xanadont
    Commented Apr 12, 2012 at 13:33
  • 1
    I think this is the most valuavle answer I have seen here. Sometimes a picture tells more than a thousand words.
    – User 1
    Commented Apr 19, 2012 at 11:48

Silly songs and scifi stories not withstanding, "You can't be your own grandpa".

  • Much the best solution for 'non technical users'. A good error message also attempts to suggest a solution to the problem (if there is one which the user can do)
    – PhillipW
    Commented Apr 11, 2012 at 16:37
  • 4
    Or can you?
    – josh3736
    Commented Apr 11, 2012 at 20:52
  • @josh3736 Compilers enforce genetic relationships, not genealogical ones. Commented Apr 18, 2012 at 20:19

Add a picture of an Ouroboros (a snake eating it's tail) to the error message.

Ouroboros Wikipedia entry for Ouroboros

  • +1 for pure cool! but -1 for not a recommendable actual solution. Commented Apr 19, 2012 at 10:44
  • That may be cool but gives the impression that the problem is isolated to 1 object, which is exactly not what a circular reference is in reality.
    – User 1
    Commented Apr 19, 2012 at 11:49

Putting that item there is like a snake eating its tail!


Parents can't be children of their own children!

  • A snake eating it's tail would make a good image below a simple explanation. Commented Apr 12, 2012 at 14:49
  • 1
    @peteorpeter Only problem is that this has reference to satanic symbolism, which could rub some users the wrong way... =\ Commented Apr 12, 2012 at 14:56

Trees have a Breadth-First traversal order; cycles don't. That means in laymans terms that you can order them such that the tree root comes first, and each node comes before its (grand)children. With a cycle, that no longer holds.

That leads us to a reasonable dialog: "A is already before B. You cannot add A after B. Do you want to move A after B? [Yes][No]"

(If true, reparent A under B. That's a standard operation and often makes sense in real-world situations. E.g. moving a whole division of a company keeping its management structure)


From the context of Your question, I assume you are trying to provide a warning/error message to the end user who is trying to build a tree like structure by adding parent of a node as it's child.

First of all, this is purely ui issue (weather or not the data structure can handle circular references is beside the point) and should be mostly avoidable by not allowing this type of situation to occur in the first place.

If you allow to pick an existing node from the tree to add as a child node, just filter out (or disable) all the parents in the hierarchy so that the parent of your current node can not be chosen for a child node.

If you are offering drag-and-drop functionality, just exclude the children of the element under cursor from the set of drop targets.

If you use "move to" type of action and pick a new parent for the item, exclude the entire subtree from the set of target nodes.

Only if there is some objective reason why you can not avoid such erroneous situations and have to provide some sort of message, try to explain it concisely and using the domain terms instead of technical language.

For example, in one of my previous project we had a hierarchical structure of Venues that had the same constraints. In there I would have formed a message that would have looked like this:

Can not move.

The {parent venue name} already contains {target venue name}.

  • I want to upvote your answer for the simple error message but can't because I completely disagree with pre-filtering the list. It's bad UI design, IMO, when the UI changes in front of the user's very eyes. It's a proverbial "pulling the rug from under their feet." "Where the hell did my choices go!?" is likely the reaction. See this: social-biz.org/2006/08/19/please-dont-disable-my-menu-options
    – xanadont
    Commented Apr 18, 2012 at 21:26
  • You may disagree with this, but ultimately, there are no hard rules (apart from the ones imposed by technical, physical or psychic constraints) when making UX decisions. It all comes down to the context of the action you are trying to perform. What's the use of providing tons of options to choose from, only to display an error message afterwards. Even worse, if most of the available choices are invalid, you leave the end user picking and choosing by random. Nevertheless, you do not have to hide invalid choices, just mark them clearly as unavailable Commented Apr 19, 2012 at 7:42
  • Mark them unavailable and why. Otherwise the user is, again, confused. And now that we're telling them why, we're back to the original question - how to explain it to them? And now we've come ... ahem ... full "circle".
    – xanadont
    Commented Apr 20, 2012 at 22:52
  • True, as befits this whole conversation we're back to where we started. :) Commented Apr 21, 2012 at 8:35
  • In a more serious tone though, it is not really that "evil" to hide the unavailable choices from the user - if in doubt, I would test my assumptions by first trying one approach and then another and give it to customers for evaluation. See how they react and then choose appropriate solution based on feedback. (PS: the famous "do not hide options" usability quote was mostly targeted at more static type of user interfaces such as menu options and thus does not apply to this context as much) Commented Apr 21, 2012 at 8:44

Tell the user this:

Imagine that you lost your Internet connection.

You call customer support and they tell you that you need to update some driver.

And that the driver must be downloaded from their web site...

  • 2
    Bad idea, don't change the topic at hand or users will be confused more.
    – Martijn_M
    Commented Apr 18, 2012 at 10:38
  • 1
    ...but still a funny explanation of "circular reference" ;-) Commented Apr 18, 2012 at 12:40
  • You can tell that to the user in a face to face conversation or support call; but it's not suitable text for the user interface.
    – Kaz
    Commented Apr 19, 2012 at 0:24
  • This is really BAD answer to the OP question and has nothing to do with UX. PS - I do think, that as explaining the concept of circular references to a layman in a casual conversation setting, this is as good as it gets, but it does not answer the OP Commented Apr 19, 2012 at 9:48

I would keep the basic text with the technical term. Users might as well learn it:

The operation could not be completed because it would cause a circular reference.

Now there would be some way to jump to a what's this? explanation:

A circular reference means that the group of items you're trying to add under an item happens to contain that item! Circular references in the item structure require more complicated handling which is currently not implemented in Frobly Software.

Ideally, there should be some advice offered to the user about what to do based on some educated guess about what they're trying to achieve.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.