The first 100% affordable housing apartment building in Brooklyn’s Pacific Park development opened Monday.

All 298 units at 535 Carlton Ave. have rents at below market rates that are distributed by the city’s affordable housing lottery.

COOKFOX, the architects behind the 18-floor building, and developers Greenland Forest City Partners said they made sure it shared the modern aesthetic of the other properties on the 22-acre development, and included amenities such as a communal terrace, gym and a bike room.

“This extraordinary building proves that affordable housing can be practical and beautiful,” said MaryAnne Gilmartin, Forest City New York president.

Monthly rents for the apartments — a mix of studios, one, two and three bedrooms — range between $578 for a studio and $3,716 for a three-bedroom. Units are slotted to affordable housing applicants with household incomes of between $20,100 for an individual and $173,415 for a family of six.

Half the units at 535 Carlton Ave. are slated for the highest income band applicants who make between $74,606 for an individual and $173,415 for a family of six.

The entire Pacific Park development project is slated to have 6,430 housing units, 2,250 of which will be affordable rentals. Two residential buildings — 461 Dean with 363 rental units and 550 Vanderbilt with 278 luxury condo units — have already opened.

Pacific Park has 479 below-rate units and another 303 units will be available this summer at 38 Sixth Ave., according to the mayor’s office.