Are both these constructions possible to mean the same thing?
- If I told you how I did it, it wouldn't be a surprise.
- If I told you how I had done it, it wouldn't be a surprise.
A past perfect like had done, however, must be related to a past Reference Time: it distinguishes an event as having taken place “before then”, not “before now”. In your second sentence the past perfect has no past time to which it may be related; the sentence is therefore ungrammatical.
What you may say is
There is however no particular reason I can think of why you should use a perfect there: you are speaking of a past event, not a present state, so the simple past did is preferred.