You asked

Which lens for portraits on the leica m d typ 262?

For portraits on the Leica M-D (Typ 262), the lens matters more than the body. The Portraits page makes this point, and it's a good match here because the M-D is a full frame camera, so lenses frame as marked. Three M-mount lenses suit the job:

The Leica APO-Summicron-M 50mm f/2 ASPH is the sensible first choice. A 50mm gives a natural perspective for head and shoulders, and f/2 is enough to separate your subject from the background. It gives up some background blur compared with a faster lens, but it's a versatile everyday portrait lens.

The Leica Summilux-M 50mm f/1.4 ASPH is the choice if you want more blur and better results in dim window light or indoors. It's faster, so it gives you a shallower depth of field at the same framing, but it's a larger and more expensive lens to carry.

The Leica APO-Summicron-M 90mm f/2 ASPH suits a more classic portrait look. The longer focal length compresses the background and keeps you further from your subject, which many people find more flattering. You need room to step back, and it's less practical in small rooms.

Whichever you choose, the light section matters more than any lens: put your subject facing a window, turn them slightly, and expose for the face. The M-D has no in-body stabilisation, so for slow shutter speeds in dimmer light, use a stabilised lens or a faster aperture.

This answer doesn't quote prices, so check each lens page for its current listing before you decide.

Written by Claude from this site's pages.

From these pages

This answer is for the question above. Each answer is written for the exact question in its address, so a question with its details in it (a budget, what you shoot, what you already have) gets an answer about those details. An answer draws on all 15 pages of the guide and its catalogue of 320 cameras and 1050 lenses. Another question gets its own answer at its own address, as words after /ask/. Or fill in your own: /ask/which-camera-for-{what-you-shoot}-under-{budget}-euros or /ask/which-lens-for-{what-you-shoot}-on-{your-camera}.