Pattern separation and pattern completion are fundamental brain processes thought to be critical for episodic memory encoding and retrieval, and for discrimination between similar memories. These processes are best understood in the hippocampus, but are proposed to occur throughout the brain, in particular in sensory regions. Cortical, as well as hippocampal, pattern separation may therefore support formation of event-unique memory traces. Using fMRI, we investigated cortical pattern separation and pattern completion and their relationship to encoding activity predicting subsequent item-specific compared to gist memory. During scanning, participants viewed images of novel objects, repeated objects, and objects which were both perceptually and conceptually similar to previously presented images, while performing a size judgement task. In a later surprise recognition test, they judged whether test items were 'same' 'similar' or 'new' relative to studied items. Activity consistent with pattern separation -responses to similar items as if novel -was observed in bilateral occipito-temporal cortex. Activity consistent with pattern completion -responses to similar items as if repeated -was observed in left prefrontal cortex and hippocampus. Curve fitting analysis further revealed that graded responses to change in image conceptual and perceptual similarity in bilateral prefrontal and right parietal regions met specific computational predictions for pattern separation for one or both of these similarity dimensions. Functional overlap between encoding activity predicting subsequent item-specific recognition and pattern separation activity was also observed in left occipital cortex and bilateral inferior frontal cortex. The findings suggest that extrahippocampal regions including sensory and prefrontal cortex contribute to pattern separation and pattern completion of visual input, consistent with the proposal that cortical pattern separation contributes to formation of item-specific memory traces, facilitating accurate recognition memory.