By Jeffrey T. Lewis

SÃO PAULO--Brazil's economy contracted slightly in the second quarter from the previous three months as industrial activity shrank due to supply problems and agriculture was hit by a decline in the coffee harvest.

Gross domestic product shrank a seasonally adjusted 0.1% from the first quarter and jumped 12.4% from the second quarter of 2020, the Brazilian Institute of Geography and Statistics, or IBGE, said Wednesday. In the first quarter, GDP grew 1.2% from the previous three months and expanded 1.0% from the first quarter of 2019.

The decline in industrial activity in the quarter was caused by the same serious supply problems that are affecting much of the rest of the world. Brazilian motor vehicle makers in particular were hit hard by the shortages, causing many plants to shut down and depressing auto production during the quarter.

"The disappointing figure reflects to a large extent the issues that have plagued the industrial sector," said Alberto Ramos, an economist at Goldman Sachs in New York. "In the auto industry, for example, there's been a lack of microchips and parts, and a significant shock to costs."

Brazil's industrial sector contracted 0.2% in the second quarter from the first and grew 17.8% from a year earlier, the IBGE said.

Brazil's economy contracted rapidly in the early months of the coronavirus pandemic last year, and only grew to reach pre-pandemic levels in the first quarter of 2021.

In the second quarter of this year, Brazil reached a peak of infections and deaths from Covid-19, with more than 4,000 deaths per day at the start of April. Since then the situation has improved, with a brief rise again towards the end of June, allowing state and local governments to ease restrictions on businesses and permitting activity to begin to recover.

Brazil's services sector expanded 0.7% in the quarter and rose 10.8% from a year earlier, while family spending was unchanged from the first quarter and increased 10.8% from a year earlier, and government spending rose 0.7% in the quarter and increased 4.2% from a year earlier.

"Almost all the components of services grew, with an emphasis on commerce and transportation... which were the activities most affected by the pandemic and which are now recovering the most," said Rebeca Palis, the coordinator of the GDP series for the IBGE.

The decline in Brazil's agriculture sector was unrelated to the pandemic, caused by droughts last year and earlier this year that reduced the size of the country's coffee harvest. Brazil is the world's biggest producer and exporter of coffee, and the country's crop follows a two-year cycle of bigger harvests in even-numbered years and smaller harvests in odd-numbered years.

The droughts cut the size of the crop even more, and agriculture declined 2.8% in the quarter and rose 1.3% from a year earlier.

Write to Jeffrey T. Lewis at jeffrey.lewisd@wsj.com

(END) Dow Jones Newswires

09-01-21 0950ET