WASHINGTON—Hillary Clinton’s use of a private email server and her lax record-keeping while secretary of state violated the department’s policies, an independent watchdog said Wednesday, a rebuke that keeps the issue alive as she campaigns for president.

Inspector General Steve Linick contradicted Mrs. Clinton’s argument that her exclusive use of a private email server while running the State Department was permitted, but offered her some cover by faulting previous secretaries of state for similar breaches. It also criticizes broader lapses at the State Department, especially regarding failures to keep adequate records of electronic communications including email dating back nearly 20 years.

He said Mrs. Clinton had an obligation to discuss her email setup with the officials responsible for security and information management at the State Department, but found no evidence that she had done so.

The report also found evidence that several hacking attempts were made against her home server, though the inspector general didn’t determine whether they were successful.

The findings are a reminder that the issue isn’t likely to fade as the presidential campaign moves toward the November election. More significant hurdles are ahead, particularly the decision by the Federal Bureau of Investigation and the Justice Department about whether to pursue any legal action in connection with the emails.