The invention relates to a verification code generation method based on hidden graphics, which comprises the following steps: S1, presetting M large graphics, each containing N sub-graphics; 2, extract n sub-graphics from N sub-graphics of each large graphics, and preprocess that n sub-graphics; 3, randomly selecte J graphics and correspond pre-processed K sub-graphics from that large graphics; 4,randomly selecte k sub-graphics as a verification code accord to that K sub-graphics obtained after the pre-processing at random; S5: setting the obtained k subgraph number series to S0; S6: outputting the selected k verification codes to the front end, and simultaneously recording the output sequence S1 of the k verification codes; S7: outputting J large graphics to the front end S8: setting a rule for selecting an implied sub-graphics; S9, recording the input and the clicking sequence of the authentication code clicked by the user, and generating the input series S0 'and the sequence sequence S1'; S10, respectively comparing the values of S0 and S0 'and the values of S1 and S1', and judging whether the authentication code input by the user is correct or not.