MOUNTAIN VIEW, Calif.

BOXES lined the cubicles and hallways in the offices of Mozilla on a recent afternoon, and its chief executive, John Lilly, seemed a bit disoriented as he looked for a place to sit. Mozilla, which makes the Firefox Web browser, had just moved from one end of this city to the other, mainly to gain more space for its growing work force.

Yet it was hard not to read symbolism into the move. Mozilla’s old offices were next door to Google’s sprawling headquarters. For several years, Google has been Mozilla’s biggest ally and patron. But in September, it also became Mozilla’s competitor when it unveiled its own Web browser, Chrome.

So it seemed only natural for Mozilla to move out from under Google’s shadow.

“We’ve learned how to compete with Microsoft and Apple,” says Mr. Lilly, a soft-spoken, earnest 38-year-old. “Google is a giant, of course, and competing with them means we are competing with another giant, which is a little tiring.”

Those big companies weren’t giving much thought to browsers when Firefox was released in 2004, and neither were most ordinary Web users. A browser was just a window onto the Web, and people used whatever was already installed on a computer. Usually that meant Microsoft’s Internet Explorer.