Handle with electronic unit

The invention relates to a handle, in particular an outer door handle for a vehicle, comprising in its interior a in the direction of a longitudinal extent of the handle tapered cavity and a valve disposed in the cavity insert, which has an at least partially overmolded with a potting compound electronics unit and which in accordance with the cavity of the handle in the direction of the longitudinal extension of the handle is tapered.