Good question! I've always immediately used the ghee I make, so I don't know; however, I do believe that by removing the milk solids, ghee becomes quite long-lived. I'd store it in a clean, sealed container in the fridge, and test it prior to using it each time. If it's rancid, it should be easy to tell.
I make ghee pretty often, and don't refrigerate it unless the weather is very hot or we're going away for a week or so. We go through it really fast, though, so that's probably part of the reason it's never gone rancid. You could also keep out a small amount and refrigerate the rest-so much easier to spread at room temp.
Hey Carminex! We've missed you over at the NJAP list! Hope you are doing well.
Anyway, I used to make my own ghee all the time. I think the reason Ghee was originally made in India is because it doesn't need to be refridgerated. But it's tricky - if you don't boil it long enough, it can get rancid, too long and it will burn.
I always cooked it over the lowest heat possible until the hissing and popping stopped... and then watched it closely until it just started to turn brown - then took it off the heat.
I believe ghee and clarified butter are the same thing. I have always heard it pronouced "gee" with a hard g sound. Basically, you heat butter up and a bunch of milk solids will come to the top forming a "scum". You scrape that off, and then pour off the clear butter leaving the other solids that have sunk to the bottom. Basically, you get an oil out of it with a butter flavor. Butter goes rancid at room temp very quicky. It also allows you to cook with it at higher temperatures than solid butter, which will smoke and scorch.