MalShare API

Anti-malware / API Key Intermediate HTTPS
Varies by plan (check documentation)

Overview

MalShare is a free community-driven repository of malware samples that security researchers upload and share for analysis. You can search for samples by hash, download files, and retrieve daily feed lists of new malware. It is useful for threat intelligence workflows where you need to verify if a file hash is known malware.

💡

Beginner Tip

Register for a free API key at malshare.com. Most operations use GET requests with ?api_key= and &action= parameters — the action parameter controls what the endpoint returns.

Available Data

stock price and symbol
open/close/high/low values
trading volume
market cap
historical price data
Use case: Integrate malware archive / file sourcing data into web and mobile applications

Example Response

JSON Response
{
  "url": "https://example.com",
  "safe": true,
  "threat_level": "none",
  "categories": [
    "clean"
  ],
  "scan_date": "2025-01-15T10:00:00Z"
}

Field Reference

MD5 MD5 hash of the malware sample
SHA1 SHA1 hash of the malware sample
SHA256 SHA256 hash of the malware sample, the most reliable identifier
SSDEEP Fuzzy hash used to find similar samples even when files differ slightly
F_TYPE Detected file type, e.g. PE32 for Windows executables
SOURCES List of URLs where this sample was originally found or downloaded from

Implementation Example

const url = "https://malshare.com/";
// Replace headers or query params with the values required by this API.
const response = await fetch(url, {
  headers: {
  "X-API-Key": "YOUR_API_KEY"
  }
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
const data = await response.json();
console.log(data);

What Can You Build?

Note: These code examples are AI-generated and unverified. Always refer to the official API documentation for accurate usage.

Common Errors & Troubleshooting

"Error: Unknown action" The action parameter value is misspelled or not supported
Use exact action names from the docs such as getlist, details, or getsamplelist — they are case-sensitive
"Error: Sample not found" The hash you queried does not exist in the MalShare database
Double-check the MD5, SHA1, or SHA256 hash; MalShare only contains samples that have been submitted by researchers
429 Too Many Requests Free tier is limited to 2,000 API calls per day
Cache results locally and avoid re-querying the same hashes; apply for an elevated quota if needed

Matrix Score Breakdown

🌐 Reachability 30/30
⚡ Speed 5/20
🔒 Security 15/15
🛠 Developer XP 9/20
✓ Reliability 10/15

Partially tested on Apr 5, 2026

Technical Specifications

Auth API Key
HTTPS REQUIRED
CORS NO
Category Anti-malware
Difficulty Intermediate
Verified: 2026-04-04

Similar APIs

View All →