The response of a separated flow to external forcing is investigated using input-output analysis. A laminar separation bubble is induced on the flow past a flat plate by imposing an adverse pressure gradient. We study the response of spanwise-constant perturbations to both global body forcing and local body forcing. Input-output analysis (also referred to as resolvent analysis) uses a linear operator that maps the external forcing to the response of the flow field. For this flow forced at a single frequency, the linear operator is closely approximated by an operator of rank one, and describes the optimal spatial forcing for which the resulting response has maximum amplification. Input-output analysis gives useful information about optimal actuator placement and optimal actuation frequency. It is found that the flow response is maximized when forcing at the natural frequency of the separation bubble. The optimal response mode implies that the separation bubble is receptive to upstream body forcing. The optimal forcing mode indicates that body forcing should be applied upstream of the separation bubble, and gives information about the size and shape of the region where forcing should be applied, in order to maximize the response in the separation bubble.