By Guillermo Parra-Bernal and Leonardo Goy

SAO PAULO/BRASILIA (Reuters) - Brazil's antitrust watchdog on Wednesday approved Banco Bradesco SA's purchase of HSBC Holdings Plc's <HSBA.L> local unit with some conditions, marking the latest departure of a foreign lender from one of the world's most concentrated banking markets.

Five board members of the watchdog known as Cade voted to pass the deal as long as Bradesco <BBDC4.SA>, the country's No. 3 listed commercial lender, agrees to refrain from making any rival acquisitions for at least 30 months. The remaining two board members did not cast ballots.

After sitting on the sidelines for years while local rivals bulked up through takeovers, Bradesco made a grab for HSBC Bank Brasil Banco Múltiplo SA last August. The $5.2 billion purchase allowed Bradesco to increase assets by 16 percent and add 5 million clients.

The transaction will help Bradesco cut the gap with state-controlled Banco do Brasil SA and Caixa Econômica Federal and private-sector rival Itaú Unibanco Holding SA - Brazil's top three banks by assets. Consumer groups have warned, though, that the deal could hurt competition where the top 10 banks control almost 90 percent of the industry's assets.

Domestic firms acquired 84 of 104 for-sale Brazilian banks and financial targets since 2008, Thomson Reuters data showed. The purchase will give Bradesco control of 13 percent of Brazil's banking assets, 12 percent of total deposits and the nation's third-largest loan book.

Analysts have said the deal, the largest in Bradesco's 75-year history, will test Chief Executive Officer Luiz Carlos Trabuco's ability to absorb large asset management, banking and insurance assets at a time when the economy is headed for the harshest recession in eight decades.

"We are up to the task, we have done our homework," Alexandre Gluher, a senior Bradesco vice president, told reporters at a conference call to discuss the deal on Wednesday.

Gluher expects Bradesco to finalize the integration of HSBC's 851 branches, 5 million clients and over 19,000 employees by October.

Non-voting shares in Bradesco, the bank's most widely traded class of stock, accelerated gains on the news. The shares rose 3.3 percent to 25.03 reais, the highest level in three weeks.

TOO TOUGH

The HSBC exit highlights the impact of state intervention in the sector since 2012, when Brazil's government instructed state banks to aggressively cut borrowing costs. While local private-sector lenders reacted by retreating to protect profits, HSBC Bank Brasil was "caught in the middle," a source involved in the sale said last year.

HSBC Chief Executive Officer Stuart Gulliver plans to use proceeds from the sale to boost capital metrics and ensure the bank remains the biggest dividend payer among European banks.

Growing asset concentration in the hands of local lenders proved too tough for "the World's Local Bank," as HSBC is known globally. According to International Monetary Fund data, banking industry concentration in Brazil is the highest among the so-called BRICs group of the world's largest emerging market economies.

In addition, former executives at HSBC put corporate client relationships before profitability, kept branches overstaffed and failed to foresee weaker loan book quality when growth in Brazil began to wane around 2012, analysts said.

In recent years, Citigroup Inc and Societe Generale SA sold their consumer-finance operations, following the steps of Intesa Sanpaolo SA, Bank of America Corp., Credit Lyonnais SA and Banco Bilbao Vizcaya Argentaria SA since the start of the century.

Citigroup <C.N> this year announced plans to sell retail banking operations in Brazil, leaving Spain's Banco Santander SA as the only major foreign retail lender in Brazil.

(Additional reporting by Lawrence White in London; Editing by Matthew Lewis and Chizu Nomiyama)