09/25/2013 09:39 am ET Updated Nov 25, 2013

Washington, D.C. Among Nation's Most Generous Cities

The United States has had a long history of volunteerism -- from Benjamin Franklin's first volunteer firehouse to the countless soup kitchens set up during the Great Depression -- and that tradition of volunteering continues today. In 2012, nearly 65 million Americans volunteered, each providing a median of 50 hours of help to charitable organizations throughout the nation. The World Giving Index ranks the United States as the fifth most generous country in the world.

Residents in the nation's capital should be proud of their generosity, as Washington, D.C. has just been ranked as one of the country's most generous cities.

The ranking comes from consumer finance website NerdWallet, which took a look at the following factors to see which places in the U.S. were the most generous:

• Volunteer rates: What percentage of residents volunteered in the past year?
• Number of hours volunteered: How many hours a year are residents volunteering?
• Financial contributions: How much of their income are residents donating?

NerdWallet analyzed 366 places based on these three factors, using data from the Corporation for National & Community Service and the Chronicle of Philanthropy.

Interestingly, most of the top 20 cities were small or medium-sized, with only D.C. and two other cities having populations of more than a quarter-million people. The study found that nearly a third of Washingtonians volunteer each year, offering an average of 42.1 hours of service per year. Those in D.C. also contribute 5.5 percent of their income to charitable organizations.

The other large cities on the top 20 list were Colorado Springs, Colo. and Charlotte, N.C. The top 3 spots all went to Utah cities. Provo topped the list, followed by Ogden and Salt Lake City. See the full list of the nation's most generous cities here.

Follow NerdWallet on Twitter: