Where to insert a custom item in /etc/hosts file?
You can add it anywhere you want in the body of the file.
Additionally the following works also:
127.0.0.1 localhost website.dev website.org
and for me even this works (but I don't think it's recommended):
127.0.0.1 localhost, website.dev, website.org
For the sake of a better overview I prefer:
127.0.0.1 localhost
127.0.0.1 website.dev
127.0.0.1 website.org
255.255.255.255 broadcasthost
...IPv6 stuff...
I guess the only difference would be that if you write your own lines after the first one, they will be found earlier than if they are in the last lines. As long as you don't have a huge amount of lines in your /etc/hosts
file that shouldn't really make a difference though.
I personally would add my own entries after the last line because I like to clearly separate my own stuff from the system's default stuff.