11 ms·
Show HN: What colour is your IP address?
- arb99 14y agohonestly who cares what 'colour' an ip address is? plus, it doesn't work "Your IP Address is We can't find it... Sorry! "
- LukaD 14y agoDoesn't work for me either. I'm guessing it interprets the 4 octets as RGBA or something similar. It's a cute idea.
- quarterto 14y agoIt's the first 3 octets as RGB, shuffled around to create complementary and triad colours.
- pcole 14y agoHey guys. Sorry its not working, its on a shared hosting, hosting it somewhere else right now. Its just a bit of fun really, grabs the first 3 numbers of your ip, turns that into an rgb color then generates a color pallet.
- eksith 14y agoMight I recommend a VPS? Don't worry, I'm not getting comission, but Digital Ocean has pretty reasonable prices for fun side projects like this. BTW, this works flawlessly for me on FF, but I wish my colors were prettier though ;)
- MathieuLoutre 14y agoIt's using http://jsonip.com/ http://jsonip.com/ apparently. Does going to this URL works for you?
- Kartificial 14y agoDoesn't work for me in Fx 18 but it does seem to work in Chrome (both Win7)
- JackWebbHeller 14y agoPeople are bashing this for being 'pointless', but hey, so is the next great to-do list app you made in 48 hours. This is a fun little experiment. I can see an actual use for this. Look for example at Identicons, Wavatars, and MonsterIDs[1]. They all use browser variables to generate random avatars for use around the web, e.g. on blog comments. I imagine this could do something similar, and a nice colour palette is a little more classy than a monster. [1] http://blog.gravatar.com/2008/04/22/identicons-monsterids-and-wavatars-oh-my/ http://blog.gravatar.com/2008/04/22/identicons-monsterids-an...
- duiker101 14y agoI don't think that I can agree enough with this comment. Pointless are only comments point it out. How many people ask what they could do to learn programming? A lot, and I don't like all the "read books & watch videos", working on a little project like this is a great thing to learn many good things while doing something more fun than the common notepad or to-do-list
- Shish2k 14y agoI was considering something related for my own software -- giving some level of differentiation to "Anonymous" users in a discussion, to reduce samefagging; users on the same subnet would get similar colours, etc. The main downside with that is that it's then plausible to look at somebody's colour and work out their IP address :P
- Udo 14y agoJust hash the actual IP address. For example, take the IP and apply MD5; then take three bytes each to make, say, 3-colored "flags". That would totally work and yet be reasonably anonymous. This would also take care of the fact that colors come as three byte values and not four.
- deleted 14y ago[deleted]
- dllthomas 14y ago
- kami8845 14y agoSo who's going to create a colour map for these?
- deleted 14y ago[deleted]
- donquix 14y agoLooks like you've got a stray </script> closing tag. It didn't work in Firefox on Mountain Lion, but it did in Chrome. I like it!
- mseebach 14y agoCute little thing :) - but: A pallet is a flat transport structure that supports goods in a stable fashion while being lifted by a forklift, pallet jack, front loader or other jacking device. A palette is a given, finite set of colors for the management of digital images.
- imhobson 14y agoHeh, thanks for the correction - will make that change now!
- pcole 14y agoThanks! Its crazy how many little typos and issues get exposed by the HN crowd even for a tiny experiment like this :-)
- skeletonjelly 14y agoFree crowdsourcing!
- jimmaswell 14y agoSince this seems not to work, I made one that does. http://luna.thehorseplace.us/ipcolor.php http://luna.thehorseplace.us/ipcolor.php
- Aardwolf 14y agoThe 4th byte is thrown away... You could use it as alpha channel? Or CMYK color.
- imhobson 14y agoConsidered it, but CMYK only go up to 100 in value - alpha channel could be an option though...
- chime 14y agoYou can name the color too - http://chir.ag/projects/ntc/ http://chir.ag/projects/ntc/ It's not an exact match of course but I did my best to make it as close as possible.
- snogglethorpe 14y agoThis is really cool, and useful. [and for all the silly color names out there, it's actually pretty amazing how right most of the names that pop out of this tool seem... most really do capture the essence of the color.]
- kenbellows 14y agoSince it's out of 100, you could do CMYK based on proportion. e.g.: C = (byte1/255)x100; M = (byte2/255)x100; Y = (byte3/255)x100; K = (byte4/255)x100;
- siddboots 14y agoFWIW, due to the way that the IPv4 address space is allocated, you could achieve far fewer "collisions" (i.e. different IPs producing the same palette) by throwing away the first byte instead. http://www.iana.org/assignments/ipv4-address-space/ipv4-address-space.xml http://www.iana.org/assignments/ipv4-address-space/ipv4-addr...
- niix 14y agoHmm would be neat if the site saved the color scheme the user's IP created and showed a list of them sans the actual address. But then again, the users IP could be easier figured out by the colors as well :)
- bnewbold 14y agoWhat, no IPv6? :(
- marios 14y agoAs a follow up to your little project, find out a way to color IPv6 addresses ::] *edit: changed standard smiling emoticon to IPv6 smiling emoticon :P
- orangethirty 14y agoI think this is very cool. A very creative way of showing off skills. Does it help me with anything right now? I'm not sure. But it does show outside the box thinking. I would definitely hire someone with such thought process.
- zuppy 14y agoYou need to do something with the text over the color pallette. It took me a while to see that there's actually something there and not a black background http://dl.dropbox.com/u/2311018/temp/ipcol.png http://dl.dropbox.com/u/2311018/temp/ipcol.png (I don't care that you can see my ip, it's not private).
- amputect 14y agoMy IP address is a calming shade of green. That's not really a thing I expected to learn today, but I'm oddly pleased by it.
- imhobson 14y agoHere's a short blog post to go with this little project we made! http://meetstrange.com/blog/pretty-ip/ http://meetstrange.com/blog/pretty-ip/
- tlrobinson 14y agoI like how you blur out the IP address but it could be trivially recovered by sampling the colors :)
- obviouslygreen 14y agoYikes... it looks like my IP is about as good at color coordination as I am.
- imhobson 14y agoWas it obviously green?
- obviouslygreen 14y agoClearly.
- epochwolf 14y agoShame. Mine is kind of cool.
- jere 14y agoNeat. This kind of reminds me of something I did a while back: I had a permissions manager that let you drag and drop groups to various actions, but the color of each group was determined by hashing their the group ID into a color. The resulting colors had no special significance, but the important point is they never changed and it let you easily visualize what was going on. I'm sure this had been done many, many times before. The difference here is that the straightforward conversion from IPs to colors means similar IPs will look very similar, whereas hashing some value to a color results in similar values looking vastly different.
- stephengillie 14y agoNeat project! This got me thinking - Why are QR codes black and white? Couldn't they transmit more information if they used colors?
- raylu 14y agoDifferent cameras and software will do different kinds of automatic white balance correction but nobody will screw it up so bad that you can't differentiate black from white.
- philsnow 14y agoWell, there are various color-based schemes like http://en.wikipedia.org/wiki/High_Capacity_Color_Barcode http://en.wikipedia.org/wiki/High_Capacity_Color_Barcode
- rachelbythebay 14y agoThis seems to run as a script in your browser, and then calls out to some helper to get your IP address. The original server (the one which hands you the script in the first place) should have your IP address already, and in theory, could create the page on the fly. That would make it work even with NoScript or similar in force. I guess client-side is the way most people do things these days.
- Cogito 14y agoThis way the server can serve a static cached page, and distribute the work to derive the colour palette to the clients. I agree that the server could do this, and for a small app like it is this wouldn't even be a big problem, however there is almost no impact on the end user and this way scaling is handled by 'better caching' and serving static pages faster. Offloading to the client is a good thing in general, and I think there are few cases where it is possible but not the better option.
- rachelbythebay 14y agoThe work to derive the palette? Do you mean RGB to HSL and back? That isn't particularly CPU-intensive. One of many implementations: http://axonflux.com/handy-rgb-to-hsl-and-rgb-to-hsv-color-model-c http://axonflux.com/handy-rgb-to-hsl-and-rgb-to-hsv-color-mo... I imagine you could precompute the entire 24 bit range if you really wanted. I mean, this thing has a failure mode where it says it can't find your IP address. That makes no sense until you look at how it was implemented.
- rdl 14y agoIt would be nice if there were a less trivial mapping of IP address to color -- something where ASN boundaries mattered, and maybe where netmask got taken into account. (so a bunch of users on /29s and /30s within the same IP block got related but different (and ideally distinguishable) colors. It would still be a canonical IP to color mapping, but it wouldn't be as literal a mapping of 32-bit address into 32-bit color.
- meej 14y agoNeat! My place of work has a surprisingly attractive IP address palette. It would be cool if you could specify an IP address; I'd like to see what the IP for my hosted VM looks like. (I suppose I could set up an SSH tunnel if I am really curious...)
- jrockway 14y agoI'd like to see what the IP for my hosted VM looks like Step 1: determine IP address Step 2: interpret the first three octets as red, green, and blue respectively Step 3: there is no step 3.
- moccajoghurt 14y agoCoding stuff for shits and giggles is the spirit that makes a good programmer.
- gsiener 14y agoThis would be a great bash addition for anyone that sshs into servers all day. Just as some people color their console red in production or green for staging, this would be a nice indicator of where you were.
- zabomber 14y agoIt's bugged.. Second pallete shows "183" instead of "173" http://imagebin.org/247232 http://imagebin.org/247232
- skot9000 14y agoI used something similar to differentiate between users on http://wrd.skot9000.com/ http://wrd.skot9000.com/