As you know, when an account is deleted, the name of the user is set to their id, say user123.

Can we know the name(s) of this user when was an active account?

I did check data.SE but found nothing about this. Maybe through other sources?


  • 1
    $\begingroup$ Possibly you could infer something from comment replies on their posts (and to their comments) - although it is to some extent guesswork. There used to be a tool to list old usernames. The webpage no longer works, it seems that from Wayback Machine you can get the JavaScript code it used, see here and here. $\endgroup$ Commented Sep 30, 2019 at 16:35
  • $\begingroup$ The same script is mentioned on Stack Apps: Find old display names of a user. However, I do not know enough about JavaScript to be able to say whether it can be modified in some way so that it works for deleted users. $\endgroup$ Commented Sep 30, 2019 at 16:37
  • $\begingroup$ @MartinSleziak thank you. When I did click on Old display names of a user in your last link, shows "404 There isn't a GitHub Pages site here." doesn't even work for current active users. Thanks anyway. $\endgroup$
    – user486983
    Commented Sep 30, 2019 at 17:22
  • 2
    $\begingroup$ Yes, I have explicitly mentioned that the page no longer works. (Maybe I should have user the wording "no longer exists".) Still, you could be able to find the JavaScript that was used in the Wayback Machine - and try to use it yourself if you have enough time to tinker with it. $\endgroup$ Commented Sep 30, 2019 at 17:35

1 Answer 1


EDIT: Originally I suggested using SEDE (see below). But probably a better option is to use some tool getting data about the usernames from Stack Exchange API, such as the one mentioned in the comments. (It is also mentioned in some other places - on this meta: To whom am I replying?, on Meta Stack Exchange: Make the “past names” list public info for 30 days after changing your name, and on Stack Apps: Find old display names of a user.)

The link where this tool was originally available no longer works. I have used the stuff available in Wayback Machine and managed to get a working version out of it. I have placed it on my website: http://msleziak.com/stackexchange/oldusernames/ - I have posted also some screenshots in my chatroom. Some more details - including the comparison of two approaches and some cases when it does not work - can be found in my post on MathOverflow Meta: Recognizing identifiable users changing user names.

Here is the answer which I posted originally:

One reasonable thing to do might be to check whether Google still remembers something about the given user and whether something can be found in the Wayback Machine. (I took one particular userid for testing - of course, the same can be done if we replace this by userid of another user.)

But possibly we can find something also from Data Explorer. (I have reworked my original attempt a bit.)

Using SEDE we can check comments/posts by a deleted user. If comments following them contain some comment reply ("@username"), it is quite likely that this might be the user in question. So at least some guess can be deduced from this.

Of course, you will get some reasonable results only for users who often engaged in discussions in comments.

I have no doubts that the queries can be improved in various ways by people who know more about SQL than I do.

One caveat to add is that some users tend to change their username relatively often. In such cases, the results could be rather inconclusive. You can check replies to comments and posts by one such users. (Possibly similar queries for existing users who tend to change their username might give you some guesses about their past usernames.)

  • 1
    $\begingroup$ Oh so the queries are in SQL. Is it like Java in difficulty? $\endgroup$
    – user486983
    Commented Sep 30, 2019 at 17:50
  • $\begingroup$ SQL is easier to learn compared to Java. It has fewer concepts and less syntax. $\endgroup$ Commented Sep 30, 2019 at 21:37
  • $\begingroup$ @AymanHourieh ohh $\endgroup$
    – user486983
    Commented Jan 30, 2020 at 19:10

You must log in to answer this question.