A recent Bloomberg article reported that billionaire Bill Gates has pledged to remain involved with Warren Buffett's company, Berkshire Hathaway (NYSE:BRK-A), for the rest of his life. The two have strong connections; Gates sits on Berkshire's board, and Buffett has pledged the lion's share of his tens of billions of dollars to Gates' charitable foundation.

Gates also suggested that he's committed to preserving what makes Berkshire great -- including its culture. Buffett has developed a culture at his company where it's understood that growth and cash generation are paramount, but not at the expense of integrity. Buffett rewards performance, but frowns on the likes of stock options. He likes to find managers with a strong sense of ownership in and love of their company, too.

Reading about Gates' pledge reminded me how important a company's culture can be. After all, it reflects a firm's identity in the world. It reassures employees and informs prospective employees. Think, for example, of modern-day giants such as Google (NASDAQ:GOOG) and Apple (NASDAQ:AAPL) and the cultures they've built. Their workplaces don't evoke the old stereotype of fellow technology giant IBM (NYSE:IBM), with its employees in blue suits and ties. Google, Apple, and many other companies have gotten where they are through innovation, and they keep that as part of their culture.

Other companies have also developed key culture traits, such as Southwest Airlines (NYSE:LUV) and its dedication to fun. It cultivates that even with customers, encouraging flight attendants to make jokes on board. Costco (NASDAQ:COST) is known for being dedicated to offering customers low prices -- and also for paying its employees well while CEO Jim Sinegal doesn't go home with the tens of millions that some CEOs do. Some have suggested that Sinegal's humble beginnings in the warehouse have fueled the company's simple and fair culture.

Culture crisis
Sometimes corporate cultures face challenges. This can happen when a new sheriff rides into town -- or a new CEO. Think back to Home Depot (NYSE:HD), for example. It describes its corporate culture in warm terms on its website, as one of generously giving back to the community. Its values include "taking care of our people" and "doing the right thing" and "respect for all people."

But it experienced a big bump in the road in 2006 when then-CEO Bob Nardelli helmed a disastrous annual meeting. What was so bad about it? Well, no questions were answered, no votes were taken, no outside directors attended, and the whole thing lasted 30 minutes. This was taken as a big slap in the face by those shareholders who'd attended, and word of the hasty meeting spread. Some shareholders sold their stock as a result, and employees were certainly dismayed by how their company represented itself. Nardelli eventually left the company with a huge severance package.

What went wrong? Well, part of the problem was probably a bad culture fit. Nardelli has a military background and was reportedly operating in a military style in a company that had been established with a more entrepreneurial spirit and where local managers had considerable power.

Culture matters
The famous Home Depot annual meeting is a stark counterpoint to Warren Buffett's Berkshire Hathaway meetings, where Buffett and his partner, Charlie Munger, answer questions for a long time. It's interesting that when asked about his succession plans, Buffett explains that there will likely be a successor who manages his subsidiary companies, and another successor who oversees investments, and a manager who maintains the company's culture. (That's likely to be his son, Howard.) The importance of company culture is not lost on Buffett.

Maintaining a consistent culture is very valuable. It informs all stakeholders about what to expect. Employees know (or learn) how the company runs and deals with changes and challenges. Customers know what the company stands for and what it offers them. And shareholders know what kind of company they've entrusted their financial future to. Imagine Southwest taking the fun out of its formula. Imagine Apple just tweaking its products from now on, with no big innovations. We'd no longer recognize the companies.

What to do
As you go about your investing, look at corporate cultures and recognize their value. Pay attention when there's turnover at the top -- make sure that the new leader is maintaining the culture. That can be as easy as informally surveying some employees.

Learn more about corporate culture and other competitive advantages:

Longtime Fool contributor Selena Maranjian owns shares of Berkshire Hathaway, Google, Apple, Costco, and Home Depot. Google is a Motley Fool Rule Breakers pick. Apple, Costco, and Berkshire Hathaway are Motley Fool Stock Advisor recommendations. Costco, Home Depot, and Berkshire Hathaway are Motley Fool Inside Value selections. The Fool owns shares of Costco and Berkshire Hathaway. Try our investing newsletters free for 30 days. The Motley Fool is Fools writing for Fools.