The recently discovered gamma-ray flares from the Crab nebula are generally attributed to the magnetic energy release in a highly magnetized region within the nebula. I argue that such a region naturally arises in the polar region of the inner nebula. In pulsar winds, efficient dissipation of the Poynting flux into the plasma energy occurs only in the equatorial belt where the energy is predominantly transferred by alternating fields. At high latitudes, the pulsar wind remains highly magnetized; therefore the termination shock in the polar region is weak and the post-shock flow remains relativistic. I study the structure of this flow and show that the flow at first expands and decelerates and then it converges and accelerates. In the converging part of the flow, the kink instability triggers the magnetic dissipation. The energy release zone occurs at the base of the observed jet. A specific turbulence of relativistically shrinking magnetic loops efficiently accelerates particles so that the synchrotron emission in the hundreds of MeV band, both persistent and flaring, comes from this site.