We prove a version of the derandomized Direct Product lemma for deterministic space-bounded algorithms. Suppose a Boolean function g : {0, 1}n {0, 1} cannot be computed on more than a fraction 1 - of inputs by any deterministic time T and space S algorithm, where 1/t for some t. Then for t-step walks w = (v1, . . . , vt) in some explicit d-regular expander graph on 2n vertices, the function g (w) def = (g(v1), . . . , g(vt)) cannot be computed on more than a fraction 1 - (t) of inputs by any deterministic time T/dt - poly(n) and space S - O(t) algorithm. As an application, by iterating this construction, we get a deterministic linear-space "worst-case to constant average-case" hardness amplification reduction, as well as a family of logspace encodable/decodable error-correcting codes that can correct up to a constant fraction of errors. Logspace encodable/decodable codes (with linear-time encoding and decoding) were previously constructed by Spielman (1996). Our codes ha...