Trademe - Cryptocurrency Trading Platform
Login to Trading
Demo Credentials: Username / Password
Live Updates: Crypto prices update every 5 seconds
Live Market Prices
Account Information
Account Type
Premium Trader
Start trading to build your balance and see your trading history!
Trading History
No trades yet. Start trading to see your history!
Trading Features
INR Pricing
All cryptocurrency prices displayed in Indian Rupees for easy understanding and trading.
110 Second Timer
Each trade runs for exactly 110 seconds with real-time countdown and profit tracking.
Double Profit Bonus
Sell in the last 20 seconds of any trade to double your profit potential!
Real-time Updates
Live cryptocurrency prices updated every 5 seconds for accurate trading decisions.
Trading History
Complete record of all your trades with profit/loss tracking and detailed analytics.
Safe Trading
Simulated trading environment - perfect for learning without real money risks.
SELL
Trading Rules:
- Trade duration: 110 seconds
- Double profit in last 20 seconds
- Minimum investment: ₹10
- Real-time profit tracking
`;
document.body.appendChild(modal);
}
// Close trading modal
function closeTradingModal() {
const modal = document.getElementById('tradingModal');
if (modal) {
modal.remove();
}
}
// Current balance
let currentBalance = 10;
let activeTrades = [];
let tradeHistory = [];
// Start trade
function startTrade(cryptoId, tradeType) {
const amount = parseFloat(document.getElementById('investmentAmount').value);
if (!amount || amount < 10) {
showError('Minimum investment amount is ₹10');
return;
}
// Allow trading even with ₹0 balance for demo purposes
const crypto = cryptoData.find(c => c.id === cryptoId);
const tradeId = Date.now();
const trade = {
id: tradeId,
cryptoId: cryptoId,
cryptoName: crypto.name,
cryptoSymbol: crypto.symbol,
type: tradeType,
amount: amount,
entryPrice: crypto.price,
startTime: Date.now(),
duration: 110000, // 110 seconds
isActive: true
};
activeTrades.push(trade);
closeTradingModal();
showTradeTimer(trade);
showSuccess(`${tradeType.toUpperCase()} trade started for ${crypto.name}!\nAmount: ${formatINR(amount)}\nDuration: 110 seconds`);
// Update balance display
updateBalanceDisplay();
// Update trading history
updateTradingHistory();
}
// Update trading history display
function updateTradingHistory() {
const historyDiv = document.getElementById('tradingHistory');
if (tradeHistory.length === 0) {
historyDiv.innerHTML = '
No trades yet. Start trading to see your history!
';
return;
}
let historyHTML = '
';
tradeHistory.slice(-10).reverse().forEach(trade => {
const duration = Math.round((trade.endTime - trade.startTime) / 1000);
const isProfit = trade.profit >= 0;
historyHTML += `
${trade.type.toUpperCase()} ${trade.cryptoSymbol}
${formatINR(trade.amount)}
${isProfit ? '+' : ''}${formatINR(trade.profit)}
Entry: ${formatINR(trade.entryPrice)} → Exit: ${formatINR(trade.exitPrice)} | Duration: ${duration}s
`;
});
historyHTML += '
';
historyDiv.innerHTML = historyHTML;
}
// Show trade timer
function showTradeTimer(trade) {
const timerModal = document.createElement('div');
timerModal.id = `tradeTimer_${trade.id}`;
timerModal.style.cssText = `
position: fixed;
top: 20px;
left: 20px;
background: white;
border-radius: 12px;
padding: 20px;
box-shadow: 0 10px 30px rgba(0,0,0,0.3);
z-index: 1001;
min-width: 300px;
border: 3px solid ${trade.type === 'buy' ? '#10b981' : '#ef4444'};
`;
timerModal.innerHTML = `
${trade.type.toUpperCase()} ${trade.cryptoSymbol}
Amount: ${formatINR(trade.amount)}
Current P&L:
₹0.00
`;
document.body.appendChild(timerModal);
// Start countdown
const startTime = Date.now();
const timerInterval = setInterval(() => {
const elapsed = Date.now() - startTime;
const remaining = Math.max(0, Math.ceil((trade.duration - elapsed) / 1000));
const timerElement = document.getElementById(`timer_${trade.id}`);
const pnlElement = document.getElementById(`pnl_${trade.id}`);
if (timerElement) {
timerElement.textContent = remaining;
// Double profit in last 20 seconds
if (remaining <= 20 && remaining > 0) {
timerElement.style.color = '#f59e0b';
timerElement.parentElement.style.background = '#fef3c7';
}
}
// Update P&L
if (pnlElement) {
const currentCrypto = cryptoData.find(c => c.id === trade.cryptoId);
const priceDiff = currentCrypto.price - trade.entryPrice;
let pnl = (priceDiff / trade.entryPrice) * trade.amount;
if (trade.type === 'sell') {
pnl = -pnl;
}
// Double profit in last 20 seconds
if (remaining <= 20 && remaining > 0) {
pnl = pnl * 2;
}
pnlElement.textContent = formatINR(pnl);
pnlElement.style.color = pnl >= 0 ? '#10b981' : '#ef4444';
}
if (remaining <= 0) {
clearInterval(timerInterval);
autoCloseTrade(trade.id);
}
}, 1000);
}
// Close trade manually
function closeTrade(tradeId) {
const trade = activeTrades.find(t => t.id == tradeId);
if (!trade) return;
finalizeTrade(trade);
}
// Auto close trade
function autoCloseTrade(tradeId) {
const trade = activeTrades.find(t => t.id == tradeId);
if (!trade) return;
finalizeTrade(trade);
showInfo('Trade completed automatically!');
}
// Finalize trade
function finalizeTrade(trade) {
const currentCrypto = cryptoData.find(c => c.id === trade.cryptoId);
const priceDiff = currentCrypto.price - trade.entryPrice;
let profit = (priceDiff / trade.entryPrice) * trade.amount;
if (trade.type === 'sell') {
profit = -profit;
}
// Check if double profit applies
const elapsed = Date.now() - trade.startTime;
const remaining = Math.max(0, Math.ceil((trade.duration - elapsed) / 1000));
if (remaining <= 20) {
profit = profit * 2;
}
// Update balance
currentBalance += trade.amount + profit;
// Add to history
tradeHistory.push({
...trade,
endTime: Date.now(),
exitPrice: currentCrypto.price,
profit: profit,
isActive: false
});
// Remove from active trades
activeTrades = activeTrades.filter(t => t.id !== trade.id);
// Remove timer
const timerElement = document.getElementById(`tradeTimer_${trade.id}`);
if (timerElement) {
timerElement.remove();
}
// Update balance display
updateBalanceDisplay();
// Update trading history
updateTradingHistory();
// Show result
const resultMessage = profit >= 0 ?
`Trade Successful! 🎉\nProfit: ${formatINR(profit)}` :
`Trade Loss\nLoss: ${formatINR(Math.abs(profit))}`;
if (profit >= 0) {
showSuccess(resultMessage);
} else {
showError(resultMessage);
}
}
// Update balance display
function updateBalanceDisplay() {
const balanceElements = document.querySelectorAll('.balance-amount');
balanceElements.forEach(el => {
el.textContent = formatINR(currentBalance);
});
}
// Notification functions
function showSuccess(message) {
showNotification(message, 'success');
}
function showError(message) {
showNotification(message, 'error');
}
function showInfo(message) {
showNotification(message, 'info');
}
function showNotification(message, type) {
// Remove existing notifications
const existing = document.querySelector('.notification');
if (existing) {
existing.remove();
}
const notification = document.createElement('div');
notification.className = `notification alert alert-${type === 'error' ? 'danger' : type}`;
notification.style.cssText = `
position: fixed;
top: 20px;
right: 20px;
z-index: 1000;
max-width: 400px;
padding: 15px 20px;
border-radius: 8px;
box-shadow: 0 10px 30px rgba(0,0,0,0.3);
animation: slideIn 0.3s ease;
`;
if (type === 'success') {
notification.style.background = '#10b981';
notification.style.color = 'white';
} else if (type === 'error') {
notification.style.background = '#ef4444';
notification.style.color = 'white';
} else {
notification.style.background = '#3b82f6';
notification.style.color = 'white';
}
notification.innerHTML = `
`;
document.body.appendChild(notification);
setTimeout(() => {
notification.remove();
}, 5000);
}
// Add CSS animation
const style = document.createElement('style');
style.textContent = `
@keyframes slideIn {
from {
transform: translateX(100%);
opacity: 0;
}
to {
transform: translateX(0);
opacity: 1;
}
}
@keyframes fadeIn {
from { opacity: 0; }
to { opacity: 1; }
}
`;
document.head.appendChild(style);
// Initialize crypto grid on page load
populateCryptoGrid();
// Initialize balance display
updateBalanceDisplay();